cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X

Need some help to solve differential equation with AdamsBDF solver

주봉_10843142
5-Regular Member

Need some help to solve differential equation with AdamsBDF solver

Hello,

 

Currently I have been facing some errors to solve differential equations using AdamsBDF solver.

Your kind help or advice will be very much appreciated.

Please see the belwo images and attached file for equations and the problem with "D"_Red Circle.

 

_10843142_1-1706359609828.png

 

_10843142_2-1706359662374.png

 

Thank you.

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

When you defined D(t,X) you type a square bracket for the second entry and so you created inadvertently a 1x1 matrix .

Simply use 'normal' parentheses and its works:

Werner_E_0-1706559266952.png

BTW, there is no need to use a solve block when you use one of the stand alone ODE solvers. A solve block is needed only when you use 'odesolve'.

 

You may get a smoother result if you either increase N significantly or use a smaller interval [Ti; Tf], or both:

Werner_E_1-1706559695337.png

 

 

View solution in original post

2 REPLIES 2

When you defined D(t,X) you type a square bracket for the second entry and so you created inadvertently a 1x1 matrix .

Simply use 'normal' parentheses and its works:

Werner_E_0-1706559266952.png

BTW, there is no need to use a solve block when you use one of the stand alone ODE solvers. A solve block is needed only when you use 'odesolve'.

 

You may get a smoother result if you either increase N significantly or use a smaller interval [Ti; Tf], or both:

Werner_E_1-1706559695337.png

 

 

In case you are interested, here is the system solved using a solve block with odesolve.

Werner_E_2-1706560240207.png

Prime 9 sheet attached

 

Top Tags