- 阅读权限
- 255
- 威望
- 0 级
- 论坛币
- 50288 个
- 通用积分
- 83.6306
- 学术水平
- 253 点
- 热心指数
- 300 点
- 信用等级
- 208 点
- 经验
- 41518 点
- 帖子
- 3256
- 精华
- 14
- 在线时间
- 766 小时
- 注册时间
- 2006-5-4
- 最后登录
- 2022-11-6
|
- Example 5.7 Please solve the inverse Laplace transform problem numerically to the
- function given in Example 5.3.
- Solution It can be seen from the earlier example that, although the analytical solution does
- not exist, a high-precision numerical solution can be found with Symbolic Math Toolbox. For
- the same function, the variable x can be substituted by s and can be converted to a string
- with char() function. Numerical inverse Laplace transform can be obtained. Compared with
- exact method, the maximum relative error is 0.005826%.
- >> syms x t; % declare symbolic variables and the function
- G=(-17*x^5-7*x^4+2*x^3+x^2-x+1)...
- /(x^6+11*x^5+48*x^4+106*x^3+125*x^2+75*x+17);
- f=ilaplace(G,x,t); fun=char(subs(G,x,’s’)); % convert to string of s
- [t1,y1]=INVLAP(fun,0.01,5,100); tic, y0=subs(f,t,t1); toc
- y0=double(y0); err=norm((y1-y0)./y0) % evaluate the error
复制代码
|
|