The PTC Community is on temporary read only status in preparation for moving our community to a new platform. Learn more here
Hey there.
I've been trying all sorts of different ways to try and get this solver to work. Different errors depending on the way I approach it. I believe it should solve. None working. all help would be amazing.
Really the two outputs i care about are R_o and h_2.
Thanks!
Hi,
Have found two subtle errors but do not know enough about the problem to solve them. A third not sure what to do.
One)
You have defined C2 = -8 in the guess values but as an undefined function in the Constraints. Needs to be fixed.
Two)
Is a units problem. Ct, C1 are defined as mm units but c2 is defined with no units. Equation in Constraints Combined section is thus unit inconsistent.
Three)
There are seven unknowns to find usually this is matched by seven equations but there are eight equations in the constraints section not sure if this matters.
Cheers
Terry
I guess that the constraints involving the C values are superfluous, since Ct and C2 are known, and C1 is known when h2 is known. so I get:
The solution is rather big, but you can solve the individual variables with:
etcetra.
Note that there are two solutions to the problem (Or I made a mistake).
Then define the knowns:
And calculate the results:
Observe that the difference between the two solutions is in ro, which is imaginary, so this solution is probably not what you are looking for (check your equations).
You can calculate C2 hrom h2.
Success!
Luc
I agree that the constraints involving the C-values could/should be omitted.
They can be combined in one equation
which means introducing a new seventh equation without providing a new, seventh variable to jiggle around. So Prime would not be able to find a solution for this system of seven equations in just six variables.
I can confirm your solutions
As you said they only differ in the sign of the imaginary ro. Variable ro only occurs squared and obviously with the equation given the only solution possible is with ro2 < 0.
If we omit the "C-equations" in the solve block, we get a different, all real, set of solutions. This is because a solve block will only return a non-real solution if we use a non-real guess value. A check also shows, that the six equations are NOT really satisfied by the solutions returned. This is because the errors (given in standard units meter and kg) are quite small and within the tolerance set by the system variable CTOL. If we change the standard value 10-3 for CTOL to something significant smaller, the solve block fails (no solution found)..
If we use a non-real guess value for ro, we get the same results as with the symbolic solve (one of the two):
A check shows that the six equations are satisfied with these values, but the "C-equation" is not!
So I second your conclusion - "check the equations!"
