Get Help

Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Community
- :
- PTC Mathcad
- :
- PTC Mathcad
- :
- I dont know why odesolve cant solve this

Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
08:13 AM

09-20-2018
08:13 AM

I'm trying to solve a simple differential equation dCO2L but it does not work with ode solver

I'm curios why.... Need help!

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
12:55 PM

09-20-2018
12:55 PM

Further, your differential equation is simple enough to solve. Which should save you the hassle of (trying to work with) ranges.

Don't mind the red stuff, its just that the numeric processor doesn't like undefined variables.

Success!

Luc

8 REPLIES 8

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
11:44 AM

09-20-2018
11:44 AM

Re: I dont know why odesolve cant solve this

Most probably because you've used a range in the Guess values.

Does it work if you delete from the Guess values:

L:0,1..LEND

?

Additionally: you HAVE to provide one initial condition for your C02L function. E.g. C02L(0)=0...

Success!

Luc

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
02:26 PM

09-20-2018
02:26 PM

Re: I dont know why odesolve cant solve this

Hey there!

I tried, and now it gave error commen like "There are too few equations"....

I dont understand

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
12:55 PM

09-20-2018
12:55 PM

Further, your differential equation is simple enough to solve. Which should save you the hassle of (trying to work with) ranges.

Don't mind the red stuff, its just that the numeric processor doesn't like undefined variables.

Success!

Luc

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
02:00 PM

09-20-2018
02:00 PM

Re: I dont know why odesolve cant solve this

Yes, exactly! That's why i'm so confused why such a easy one can't give me result.

Thank you very much.

Wish you all the best!

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-20-2018
03:12 PM

09-20-2018
03:12 PM

Re: I dont know why odesolve cant solve this

There's no doubt. Mathcad (and Prime too) really CAN solve this differential equation numerically. It's just that you have tro set it up correctly.

I can't show you how to do it in Prime (I'm limited to Prime express), but in Mathcad 11 it goes as follows:

I know that the way to set up a solve block for solving differential equations differs between various mathcad versions. In Mathcad 11 it's different from Mathcad 15, and Prime uses a completely different structure.

I suggest you look up the help information regarding Odesolve and work out some simple examples, to see that it really works, THEN correct your sheet....

Or you just learn how to solve differential equations symbolically (Note that Prime cannot do that out of the box, nor can Mathcad) and use those symbolical results. The calculation of/with resulting functions will(should) go faster, will work outside of the borders that you can set for a solve block, AND symbolically solving might give you some (or all) insight in what is really going on regarding the stuff you are modelling.

All that said, there ARE occasions where you really need the solve block to (numerically) approximate the function described by a differential equation (DE). This usually occurs with non-linear DE's. See for example here: https://community.ptc.com/t5/PTC-Mathcad/Nonlinear-1-ord-differential-equation/m-p/572071#M182386

Success!

Luc

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-21-2018
06:32 AM

09-21-2018
06:32 AM

Re: I dont know why odesolve cant solve this

Yeah, i tried as well in Matchad 15 and still it does not work!

You can look from the file i attached

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-21-2018
07:27 AM

09-21-2018
07:27 AM

Re: I dont know why odesolve cant solve this

Are all your constants defined?

Did you write the derivative correctly? (NOTE: Mathcad distinguishes between upper and lower case!)

Did you provide an initial condition for your function?

Did you consult the (Mathcad 15) help regarding Odesolve to see if you formatted the solve block correctly for Mathcad 15?

Success!

Luc

Highlighted
##

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

09-21-2018
10:43 AM

09-21-2018
10:43 AM

Re: I dont know why odesolve cant solve this

There are a lot of errors in your sheet.

You mixed lower case and capital "L/l"

You have a typo in front of the H in the denominator

You are missing an initial condition

You haven't looked up the correct syntax for odesolve in Mathcad 15