In the attached mathcad prime 3.1 worksheet I'm attempting to utilize a solve block to determine the actual value of the variable xNA. A guess value was used earlier in the worksheet. Although the worksheet produces no errors it's setting the solved value to whatever the guess value is. How can I stop this behavior? Is it due to incorrect constraints?
Solved! Go to Solution.
You changed nothing to the Solve block itself.
DJF is fuly right in stating that the solve block is working and doing exactly what you are asking.
But, your solve block is a bit silly, and it probably does not deliver what you had in mind.
Here's why:
You define a guess value for Xna far up.
Just above the solve block you define a target value with:
This makes sure that Equilibrium gets the value of Xna applied to that equation within absolute bars.
Now, in the solve block, you essentially request to find the value of Xna such that, when it is applied to that same equation between absolute bars, it delivers Equilibrium.
I don't need a solve block to know that the result of that is exactly: 32.018 in. In fact I don't even need to know the equation, because this holds no matter what equation you have (so long as it does not result in an error).
If you change
e.g. to
At both sides, in the definition of Equilibrium as well as in the contstraint of the solve block, you'll get the very same answer.
I think you need a different value for Equilibrium (one that not depends on the guess value of Xna)...
Success!
Luc
Looks like it's doing exactly what you told it to do. Ttot and Fc don't seem to actually change with Xna so your guess value doesn't matter. Any value will work so it stops with the guess. So go back a few steps and figure out where those functions went wrong.
Your solve block works  just try to use a guess value like 10 in or lower.
A plot may give you a hint as to whats going on:
Every value of x.NA greater than approx. 13.7 in is a valid solution for your solve block equation.
Here's one part where your functions become unrelated to Xna:

followed by:
You HAVE to make part1...4 each dependent on Xna, if you want Ttot to be dependent on Xna.
So: part1(Xna)...
Success!
Luc
Thanks LucMeekes, adding the xNA dependency to each part of the attached modified spreadsheet changed the solve block. The solve block no longer copies the guess value but instead uses the initial guess earlier. The solve block still doesn't work but it's getting closer. Perhaps I need to adjust the constraints needed to be adjusted.
You changed nothing to the Solve block itself.
DJF is fuly right in stating that the solve block is working and doing exactly what you are asking.
But, your solve block is a bit silly, and it probably does not deliver what you had in mind.
Here's why:
You define a guess value for Xna far up.
Just above the solve block you define a target value with:
This makes sure that Equilibrium gets the value of Xna applied to that equation within absolute bars.
Now, in the solve block, you essentially request to find the value of Xna such that, when it is applied to that same equation between absolute bars, it delivers Equilibrium.
I don't need a solve block to know that the result of that is exactly: 32.018 in. In fact I don't even need to know the equation, because this holds no matter what equation you have (so long as it does not result in an error).
If you change
e.g. to
At both sides, in the definition of Equilibrium as well as in the contstraint of the solve block, you'll get the very same answer.
I think you need a different value for Equilibrium (one that not depends on the guess value of Xna)...
Success!
Luc
Thanks LucMeekes, changing the constraint equation and adding xNA dependency to prior equations fixed the issue. The fixed mathcad is attached to the original post