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

The community will undergo maintenance on October 16th at 10:00 PM PDT and will be unavailable for up to one hour.

Solve block: bad solve body

Rik1982
1-Newbie

Solve block: bad solve body

My students and I use Mathcad to solve problems of dynamics. My students this year (prime 10.0.0.0) come sometimes across an unknown error when using a solve block. The error mentions "bad solve block"; refer also to the screenshot. I have never come across it before and I have no clue what the reason could be for this error.

 

After retyping the equtions and the "find" command, the solve block executes correctly. But I don't see a difference between the original solve block and the one after retyping it. So it stays a mistery why one time it executes and the other time it doesn't.

 

Schermafbeelding 2024-10-14 223314.png

1 REPLY 1
Werner_E
25-Diamond I
(To:Rik1982)

Are you sure that the equations are correct?

I notice that you defined t.0 and a.2 but they are never used.

 

Solving the system symbolically shows that you run into troubles (division by zero) if a.0 = a.1

Werner_E_0-1728942756603.png

Here I changed a.1 from 1.5 to 2.5 m/s^2 and the symbolics seem to provide a valid solution:

Werner_E_1-1728943130794.png

Unfortunately the numeric solve block still fails 😞

 

EDIT:

Ahhh! Seems you found a bug in Prime 10, Feel free to report it to official PTC support.

The problem is the inline evaluation in the definition of the guess value for v.1.

Delete it (and evaluate in a separate region if necessary) and the solve block works OK - at least if a.0 and a.1 are different!

Werner_E_2-1728943603424.png

As we have seen from the symbolic solution, there are two sets of solutions stemming from the underlying quadratic equations. In the solve block above we got the (presumably undesired) solution which includes negative values.

To get the other set of solutions you may either provide better guess values (even t.1:=9s will do the job with the values given) or you add additional constraints, for example t.1>0

Werner_E_3-1728943744258.png

 

Announcements

Top Tags