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

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

Interpolation/Solving Equation

ptc-5346620
1-Newbie

Interpolation/Solving Equation

Dear All,

I'm using Mathcad Express Prime 2.0 and I would like to solve the following equation:

L:= ((g*T^2)/(2*pi))*tanh((2*pi*d)/L)

In this equation two times the L is defined. You fill A L in and calculate the L, fill that calculated L in and recalculate untis you have the same input as output value. I don't know how to search on the web. Is this interpolation or solving. Tried interpolation but all I can find is interpolation between two poitn (linear, cubic etc).

Anyone any idea?

1 ACCEPTED SOLUTION

Accepted Solutions

In case you are still in troubles here are the two ways to get what you are searching for.

View solution in original post

8 REPLIES 8

You can use the root function in Exprass for it.

Can you explain that al little bit more?

Express has only the root function in the group Solving. And not symbolic Math

http://twt.mpei.ac.ru/ochkov/T-2013/3-04-root-2-arg.PNG

Daniel Schonfeld wrote:

Dear All,

I'm using Mathcad Express Prime 2.0 and I would like to solve the following equation:

L:= ((g*T^2)/(2*pi))*tanh((2*pi*d)/L)

In this equation two times the L is defined. You fill A L in and calculate the L, fill that calculated L in and recalculate untis you have the same input as output value. I don't know how to search on the web. Is this interpolation or solving. Tried interpolation but all I can find is interpolation between two poitn (linear, cubic etc).

Anyone any idea?

First it looks like you wantd to solve an equation for L (at least you wrote that you want to solve). Without values for g, T and d you would need symbolic operations which are not available in Express.

If you have values for the three variables you could use a solve block, but again this is considered premium feature and not available in Prime. So using root as suggested by Valery would be the way out.

But from your description later it sounds you want to implement an iteration process. Especially as you wrote you want to recalculate and stop as soon no change in value is noticable. Normally you would do so in a program (the do until no_change forces a program) but unfortunately - you guessed it - Express would not allow programming. So the best you could do is to calculate a vector of successive values of L. You can determine the number of iteration steps but you obviously can't demand sto stop at a specific condition.

If you have problem setting it up post your worksheet with the equation/function, the values for g,T and d and the initial value of L here and you sure will get help.

My apolgize, the only variable is L. In the figure below I have 3 parameter, and L_0 is the statring point of L. Filling this in, calculating the output L, filling in. etc.

tmp.png

I understand the limitation of Mathcad Express, hopefully I can make clear with these calculations that a full version is needed and the company.

@Werner, I found some iterative process is matrix form, but I don't understand how to use it in my equation.

Daniel Schonfeld wrote:

My apolgize, the only variable is L.

No, d and T are variables, too and they need to be assigned a value for the iteration to work. 😉

If you open help and type "iteration" in the search window, the first item (calculation of a square root) is a good example on how to set up an iteration the way you need it.

In case you are still in troubles here are the two ways to get what you are searching for.

Sorry was having my dinner. Your both solutions work perfect for me. Love the simplicity of the first one, nice to see how to get the answer at the second one.

Thank you very much!!

Top Tags