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

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

How to solve an equation contains 2 variable range

ptc-5029428
1-Newbie

How to solve an equation contains 2 variable range

Dear All Experts,

If we have 2 variable in a range in an equation, how can we solve it in mathcad programme.

for example in attached mathcad, the variables are:

1) x - is for the variation of pressure

2) i - the variation of layer of a pipe.

my aim is to calculate the circumferential stress through each layer by varying the pressure.

Thank you in advance

Regards

-Akmal-

1 ACCEPTED SOLUTION

Accepted Solutions

Hello Akmal,

maybe this corrected worksheet does the trick. Your matrix index went one iteration to far and I simplified, I hope correctly, the loop.

Raiko

View solution in original post

4 REPLIES 4

Hello Akmal,

maybe this corrected worksheet does the trick. Your matrix index went one iteration to far and I simplified, I hope correctly, the loop.

Raiko

Dear Raiko,

actually when i prepare just based on my pre-mature understanding on the concept and did not know really on what did the return function works for.

Anyway it does resolve my problem. Thank you very much for your help

regards

-Akmal-

Dear Raiko,

i'm not sure you did saw my follow on discussion further on to almost the same situation but a bit more complex with the one sent earlier.

Appreciate your assistance on this situation as well. Below is the message i've extracted from the other discussion topic i've opened.

Thank you in advance

Regards

-Akmal-

*************************************************************************************************************************************************************************************

Dear Andy,

i've tried both of them but still it has divide by zero.

anyway if later i manage to solve "divide by zero" the problem, i still have problem in determine my LBC value as it takes too long to calculate and i have to stop it.

The LBC is dependent on:

1) Sigma_y and Ax value where they are suppose to be linked to changes of external pressure Prx.

2) Sigma_X and sigma_XCR where they are link to the variation of bending moment.

i ammend a bit on the spreadsheet i sent earlier with some remark for clearer picture

Regards

-Akmal-

*************************************************************************************************************************************************************************************

Hello Akmal,

soryy but I haven't been in my office for some days and found your inquiry only this morning.

I hope I found the right solution because I do not understand your worksheet entirely. However, I managed to simplify the last loop in which you're computing LBC.

You did asign LBC twice therefore it didn't end. Now it's finished in a mere second.

Raiko

P.S.

As a thumb rule: if you're using some data in a loop over and over again then asign them to a constant. That accelerates any loop quite a bit.

Top Tags