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

Community Tip - Have a PTC product question you need answered fast? Chances are someone has asked it before. Learn about the community search. X

seeking for help: too few initial conditions for differential equations in mathcad

zjiang
1-Visitor

seeking for help: too few initial conditions for differential equations in mathcad

Hi,

I want to solve trwo consecutive differential equations in Mathcad 15, which is like following picture,

QQ图片20160215123848.png

Actually, I want to get the plot of S(r) with r. In addition, "r" ranges from 0 to 0.001. I don't know how to deal with my error, hope to get your help.

Please, kindly find the attachment about this task. Thank you very much.

Jason

ACCEPTED SOLUTION

Accepted Solutions
Werner_E
25-Diamond I
(To:zjiang)

Mathcad's Quickplot isn't perfect.

Either use a range variable for r

or at least set the start and end point for the plot manually:

View solution in original post

5 REPLIES 5
LucMeekes
23-Emerald III
(To:zjiang)

I'd say rather than too few initial conditions, you have too many (namely 4 instead of 2).

First of all let's establish that you have a single differential equation for the function W(r). That is because S(r) is NOT involved in the first equation.

The second equation tells that W(r) is the derivative of S(r) multiplied with a constant.

So you only have to solve the first differential equation to find W(r) and then S(r) can be found by integrating.

You might indeed say they're consecutive: one follows the other. They're not simultaneous!

Let's do some work:

I would guess that this solution implicitly assumes that  W(0)=0 and S(0)=0, which is pretty close to two of the initial conditions you've provided.

You say that r ranges from 0 to 0.001. Well here's the plot:

Does this meet your expectations?


Luc

RichardJ
19-Tanzanite
(To:zjiang)

Or, avoiding all the symbolic math,

Werner_E
25-Diamond I
(To:zjiang)

Here is a third approach, following more closely what you had tried to do:

1) You have two functions W and S - so you have to solve for both, not just for S

2) You had a typo in the last W(r). You had a multiplication W*(r)

3) You cannot chose r=0 as start value -> division by zero (first equation, if solved for the derivation of W).

4) Its was already said: you had too much initial conditions for a system of just two DE's of 1st order

Regards, Werner

zjiang
1-Visitor
(To:Werner_E)

Thank you for your detail solution. It's very useful for me. And, I 'm sorry I give the wrong first equation, the right equation is as following:

1.png

As you can see from the above picture, I still can't get the plot. I don't know why?

In addition, I have know the condition from question, S(0.001)=0.0001, which is not matched with your plot. Could you help me figure out what's wrong?


Please kindly find the attachment.


Best wishes,

Jason

Werner_E
25-Diamond I
(To:zjiang)

Mathcad's Quickplot isn't perfect.

Either use a range variable for r

or at least set the start and end point for the plot manually:

Announcements

Top Tags