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
- :
- Solve command | equation single variable

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

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

03-29-2016
07:45 AM

03-29-2016
07:45 AM

Check attached files.

My attempt is to solve for x at a certain p value. Can anyone explain why the solve command and solve block fails?

- According to Brent Maxfield's monograph “Essential PTC Mathcad Prime 3.0 (2014)” ch.10 pg. 312, the 3.0 version has a bug with modifiers which could implement constraints. Has this been fixed in 3.1? I want to eliminate complex roots and filter real roots.. Will assume command be any use in 3.1 as it make no difference in 3.0 version?
- Does the solver fail because of the expression in the equation “’x’ to the power ‘i’” where x has multiple roots and “i” is also running from 1-14, 1-17? However, in reality “i” is affiliated in sigma and when expanded it cannot be considered as a range.. Can this be sorted if I re-arrange it in vector form? Like using a vector and a poly-root command?
- Check attached file “Patek & Klomfar..”. If you look at the last 2 equations which I’ve disabled if not it will take nearly 5 hours to solve each. (Should be done one at a time) The value of x should be between 0 to 1. The results were a bit goofy like it gives me “MuPAD not responding” and the values change each time I get a proper answer. Is there an alternative method to solve this? What I have in mind is to expand all sigmas.. if that helps.
- Check attached file “test”. “i” runs from 1 to 5 thus making a polynomial max of 25 and also of a non-integer 1.25 (5/4). Mathcad took a while to get the solution but I’m only interested in real roots. Is there a way to filter the real root and save time?
- Check attached screenshot. Is it normal to have a large thick title bar when solving?

Manilka Jayasooriya

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

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

03-29-2016
10:12 AM

03-29-2016
10:12 AM

1) The assume keyword does not filter the results, it determines assumptions about the variables on the LHS. If you want to filter the results you have to assign them to a numeric variable and then filter them as a second step.

2) I assume you are referring to the solve shown in the screenshot. You are simply asking too much of the symbolic solver. That expression is far too complex for there to be a symbolic solution. You will have to solve it numerically (with a solve block, as in NEW 18......mcdx)

3) There is no such attachment

4) No. You can assign the result to a variable, and then filter the vector for real roots, but that's all.

5) No. I have never seen that before.

4 REPLIES 4

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

03-29-2016
10:12 AM

03-29-2016
10:12 AM

1) The assume keyword does not filter the results, it determines assumptions about the variables on the LHS. If you want to filter the results you have to assign them to a numeric variable and then filter them as a second step.

2) I assume you are referring to the solve shown in the screenshot. You are simply asking too much of the symbolic solver. That expression is far too complex for there to be a symbolic solution. You will have to solve it numerically (with a solve block, as in NEW 18......mcdx)

3) There is no such attachment

4) No. You can assign the result to a variable, and then filter the vector for real roots, but that's all.

5) No. I have never seen that before.

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

03-29-2016
10:55 AM

03-29-2016
10:55 AM

Re: Solve command | equation single variable

Thanks Rich..

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

03-29-2016
01:52 PM

03-29-2016
01:52 PM

Re: Solve command | equation single variable

The "assume" command is a beast and ever so often you will not get the wished for result.

But this does not mean that it fails every time, though - the example you posted works OK:

But you may run into troubles if you have more unknowns in your formula and maybe even units (which the symbolics does not know anything about). You will have to tell Mathcad singly (using "ALL" ever so often fails) for every unit and variable that its real, maybe that its positive (that implies real anyway) or, if you have expressions like sqrt(a-b), that a>=b, etc. That can be very cumbersome and there is no guarantee that it will work OK. You will have to give it a try.

WE

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

03-29-2016
02:19 PM

03-29-2016
02:19 PM

Re: Solve command | equation single variable

Here are some further examples of how to use assume to filter/constrain your symbolic calculations:

1) Filter for the positive solutions of an equation:

2) Solving an goniometric equation

lets look at ALL (infinite) solutions

or at all solutions within a given range

3) But as already stated, Mathcad symbolics is limited and so is its solver. In this example it refuses to show the second solution of the given equation.

Maybe it has to do with the fact, that muPad is here forced to switch to numeric/float mode - I don't know.

Plotting assures us as of the two solutions:

but the symbolics is not able to calculate the positive solution

we have to use Mathcads own numerics to get what we want

Facit: You have to play around and give different combinations of keywords a try. Mathcads symbolics (muPad) sure is not the best available but its all we have in Mathcad.

WE