Skip to main content
1-Visitor
December 12, 2019
Question

Help with programming

  • December 12, 2019
  • 2 replies
  • 3368 views

Hey I have a question. Since I am still quite new to this software, if you think my question is easy, please help me out. Suppose I have a value calculated at the end with different parameters. Wondering if there is any way that for each parameter, I can create a matrix or excel with two columns, one is the parameter number, and the other is the corresponding value, when keeping others constant. 

Thanks a lot!

2 replies

21-Topaz II
December 12, 2019

Hi,

 

It is easy to do what you are after, but first -> which version are you using?

Cheers

yhuang-81-VisitorAuthor
1-Visitor
December 12, 2019

I am using mathcad prime 2. Thanks!

17-Peridot
December 12, 2019

here we go.

I've added a MatCad 15 file that shows the idea.

Raiko

 

P.S.

 

had to edit, since I've uploaded wrong file.

yhuang-81-VisitorAuthor
1-Visitor
December 12, 2019

Hi Thanks a lot for your reply!

The problem I have is that the outcome variable is not a simple equation and it's been calculated after 5 or 6 pages with many other parameters too (even though we can keep other parameters constant). Wondering how you solve the problem in this case?

Thanks again!

25-Diamond I
December 12, 2019

Its stabbing in the dark without seeing what you do, but I guess you would have to turn every calculation, which uses the parameters you would like to vary at the end, into functions dependent on those parameters.

With long winded calculations as you describe it this can be pretty cumbersome and result in a wild looking worksheet.

It has bee a long standing wish of the community to be able to turn a whole worksheet into a function of a number of selectable arguments but as development is running now, that kind of wishes never will be fulfilled.

 

While I don't like the approach - Raikos way to start with vectors of input values right from the start, vectorize the calculations to end up with a vector of result values should work with long winded calculations as well (and possibly will look cleaner compared to the suggested functional approach). Where do you see a problem with that?
Guess it would help if you post a worksheet to show what exactly you are trying to attempt (a simplified one showing only the important things would be preferred).

 

BTW, as you obviously could read Raikos MC15 worksheet, you seem to have MC15 installed along with Prime 2. Why do you bother to use Prime 2 when MC15 is at your hand?