フィルターのクリア

Info

この質問は閉じられています。 編集または回答するには再度開いてください。

Error using bvp4, "singular Jacobian", when I am decreasing the value of a parameter of my equation

1 回表示 (過去 30 日間)
T S Singh
T S Singh 2016 年 10 月 23 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
I am solving a set of linear equations (reduced from a fourth order differential equations with variables coefficients) using bvp4, when I reduce the value of r2 (parameter) below 50e-9 its showing error. Any suggestions please????
clear all
close all
clc
global r1 m L mu Ao A1 A2 A3 A4 w
%%%%%parameters %%%%
L=50e-6;
r1=200e-9;
r2=10e-9;
E=1e+6;
w=35;
mu=0.001;
rh=0.3*L;
amp=1;
T=2*pi/w;
dpoint=100;
m=-(r1-r2)/L;
rav=(r1+r2)/2;
Ao=(E*pi*r1^4)/4;
A1=E*pi*r1^3*m;
A2=(3/2)*E*pi*r1^2*m^2;
A3=E*pi*r1*m^3;
A4=(E*pi*m^4)/4;
SolYinit = bvpinit(linspace(0,L,dpoint), [0; 0; 0; 0]);
Fsol = bvp4c(@hode, @hbc, SolYinit);
xcor=Fsol.x;
ycor=(Fsol.y);
%%%%%%%%%%%%%
function dydx = hode(x,y)
global r1 m L mu Ao A1 A2 A3 A4 w
r=r1+m*x;
Cn=4.*pi.*mu./(log(L./r)+0.5);
A=Ao+(A1.*x)+(A2.*x.^2)+(A3.*x.^3)+(A4.*x.^4);
Ax=A1+(2.*A2.*x)+(3.*A3.*x.^2)+(4.*A4.*x.^3);
Axx=(2.*A2)+(6.*A3.*x)+(12.*A4.*x.^2);
dydx=[y(2); y(3); y(4); (-1/A)*((2*Ax*y(4))+(Axx*y(3))+(1i*w*Cn*y(1)))];
%%%%%%%%%%%%%%%
function res = hbc(ya,yb)
res = [ya(1); ya(2)-1; yb(3); yb(4)];
  3 件のコメント
T S Singh
T S Singh 2016 年 10 月 25 日
編集済み: T S Singh 2016 年 10 月 25 日
Thanks for your quick response. The coefficient matrix is not constant (its function of independent variable 'x'). So is it okay to use \ operator? Can u please suggest me some ways to tackle the problem of having a " singular Jacobian" error when I am reducing the value of r2<50e-9, in the above program??
Walter Roberson
Walter Roberson 2016 年 10 月 25 日
To use \ the coefficient matrices have to be constants at the time the \ is called.
I do not know enough about how bv4pc works to make suggestions about why the Jacobian is becoming singular.

回答 (0 件)

この質問は閉じられています。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by