Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X
Hi All,
Relatively new to MathCAD, so apologies if there is an easy fix here.
I've prepared a calculation file that take some various data and creates a piecewise function using if statements.
The clip below shows a graph of the piecewise function, and the equation I am trying to solve.
M(9.575 ft) = 0.967 lbf is confirmation that the function M(d) is working properly. I am looking to try to solve for a value of d that will provide M(d)=0. I am getting a "Pattern Match Error" with the equation I used above.
I'm wondering if it would be helpful to solve this equation within a range, but I've hit a dead end on figuring out how to approach that.
Any help is greatly appreciated.
Thanks
Solved! Go to Solution.
the solve and the right arrow are constructs that work for symbolics. You don't have that, You simply have a function M(d) where you want to find the value of d such that M(d) equals zero.
That can be simply accomplished using the root() function.
Assign a guess value to d, then call the root function. Like this:
d:= 9*ft
dzero:= root(M(d),d)
Now you can check if dzero results in an M-value of (near) zero, e.g. with:
M(dzero)=
The result should be very small.
Success!
Luc
the solve and the right arrow are constructs that work for symbolics. You don't have that, You simply have a function M(d) where you want to find the value of d such that M(d) equals zero.
That can be simply accomplished using the root() function.
Assign a guess value to d, then call the root function. Like this:
d:= 9*ft
dzero:= root(M(d),d)
Now you can check if dzero results in an M-value of (near) zero, e.g. with:
M(dzero)=
The result should be very small.
Success!
Luc
Worked perfectly, thank youA