各位朋友大家晚上好,今天我讲解一下关于AMESim软件关于数表函数的使用方法,主要讲解一下这一个一维数表的使用: ,我们首先看一下其help文件怎么说的,其外部变量都是无量纲数值,一维数表分为两列,这两列是以什么形式做的数表呢,显然这是以插值的形式,而我们这样的数表文件一般是由试验得到的,将试验数据导出文本文件或者data文件,按照帮助中这样的格式即可。 使用方法: 1、 怎么使用呢?我们通过帮助里的一个实例来看看,看看这个恒排量泵的案例, 
2、 经过草图建模、子模型选择、编译及参数设置环节后,提交解算。我们看了其基本设置,输入值为x,我们要将时域下的两个变量曲线,做成以输入为x值,输出为y值的曲线,使用: 
3、 我们得到这样一个曲线 
这条曲线的横坐标是input signal,纵坐标是output signal。 4、 那么这个数表文件到底是什么意思,到底如何设置的呢?我们切换到参数模式下: 
参数解释,(1)插值类型,插值类型有两种,这里使用的是线性插值;(2)这个参数linear data out of range mode设置为循环,这个循环的意思是数表的数值做循环,什么意思呢,我们看看数表文件 
,这样一个数表文件

有两列数据,而这个循环就是将前面这六行数据重新来一遍,看看我做的这个循环的excel文件, 
从第六行开始循环,第六行就是360+0=360,第七行就是360+10=370,……以此类推;第十一行就是360*2+0=720,这是第二个循环,以此类推;第十六行就是360*3+0=1080,我先做前十六行的数据,大家应该明白设置循环的意思了。 5、 我们将输入数据导出,导出来的数据做成excel文件,这里的数据都是enter换行,我们要换成tab键换行, 
6、 我将第一列删除,这是时间离散值,我们这里用MatlaB做个插值算一下,验证一下我们的做法正确与否,这里我已经写了个小程序,第二个excel同样是循环的,我原来导出的是这个位置的数表 


应该是正确的理解。 文章转自技术邻
|