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

Translate the entire conversation x

How to assign a numerical value to the function to continue, when a calculation does not converge?

ajay94_shan
8-Gravel

How to assign a numerical value to the function to continue, when a calculation does not converge?

the ordinate values for W(D,M) exceeds 10^307 at some points in calculation. I want to assign 10000 to W(D,M) in those cases. Please see attached mathcad file. Thanks for A to A.

ACCEPTED SOLUTION

Accepted Solutions
Werner_E
25-Diamond I
(To:ajay94_shan)

You are using "on error" the wrong way.

It has to be the first statement (otherwise the error occurs and your routine fails) and calculation which may fail is on the RHS, not the LHS.

The following should do the job, but on first sight it looks to me that the value of M does not influence the result.

bild.png

View solution in original post

2 REPLIES 2
Werner_E
25-Diamond I
(To:ajay94_shan)

You are using "on error" the wrong way.

It has to be the first statement (otherwise the error occurs and your routine fails) and calculation which may fail is on the RHS, not the LHS.

The following should do the job, but on first sight it looks to me that the value of M does not influence the result.

bild.png

Thank you very much Werner_E  !!!!!

Announcements

Top Tags