Skip to main content
10-Marble
June 24, 2025
Solved

How do I create a table that requires calculations with different variables?

  • June 24, 2025
  • 1 reply
  • 1032 views

Hi Mathcad 10.0 Prime User,

I want to make a table with different variables. My Q is always different, on which the other variables depend on. Q has to be 2 or higher. So if someone can just show me how to do the basic table, I will than use my Q's etc. I really have no clue how this might work in Mathcad. 
File is attached. 

Thanks.

Saro

Best answer by Werner_E

There are a few pitfalls along the way.
The Solve block solves for two variables, but Prime does not allow vectors that contain function definitions.
You could do it like this:

Werner_E_0-1750783221374.png

This function with both values as the result could now be broken down again into two individual functions. Since the Solve block sometimes does not find a solution (for values of Q less than 0.809993 m³/s), this error can be intercepted using try..onerror:

Werner_E_1-1750783411779.png

Now you could use the functions for plotting,

Werner_E_2-1750783536124.png

but of course you can also use them to create a table of values

Werner_E_3-1750783617005.png

EDIT: Just noticed that in the picture I forgot to add the unit for Q in the header text. Is fixed in the attached file.

 

Prime 10 file attached

 

 

1 reply

25-Diamond I
June 24, 2025

You have to turn the expressions which are dependent on Q into functions of Q.
This also can be done using the solve block -> Parameterizing Solve Blocks

 

BTW, your thread

https://community.ptc.com/t5/Mathcad/How-to-find-two-variables/td-p/1021425/jump-to/first-unread-message

still is not closed.
If there are still any questions feel free to follow up. Otherwise consider to close the thread.

10-Marble
June 24, 2025

Thank you I forgot to close it - i closed it now. I will try your request.

Thank you for now.

 

10-Marble
June 24, 2025

But this doesn't calculate my individuelle variables in my table. Do you mean I should write Q1 = 2, Q2 = 2 and so on, but I wanted it to be less typing - so that they is a shorter way. I was thinking doing it maybe with vectors. that I say my Q :=1...10 (until whatever number), but that doesn't work with units. So that it gives me all individual variables in the table. I am not a native speaker - I can't really say it the way I want to. 

I might not understand what you mean. I kind of don't get it with the link