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

Community Tip - You can change your system assigned username to something more personal in your community settings. X

simplify program if possible

ptc-2604758
1-Newbie

simplify program if possible

dear ptc community - thanks to mike (num 1) i believe am starting a discussion right - please see attachment and see if someone will comment on it - thanks joe

1 ACCEPTED SOLUTION

Accepted Solutions

I am not sure if I fully understand what you need, but I hope that the attached file will help.

I think its best to turn your calculation in a function which has the matrix as parameter.

First routine will work for a matrix with exactly 4 columns only:

M1.png

The second routine is more versatile and will take a matrix of any dimensions - columns are speakers/resistors in series and all columns are parallel:

M2.png

EDIT: Here is a more compact version of the latter:

M3.png

View solution in original post

3 REPLIES 3

I am not sure if I fully understand what you need, but I hope that the attached file will help.

I think its best to turn your calculation in a function which has the matrix as parameter.

First routine will work for a matrix with exactly 4 columns only:

M1.png

The second routine is more versatile and will take a matrix of any dimensions - columns are speakers/resistors in series and all columns are parallel:

M2.png

EDIT: Here is a more compact version of the latter:

M3.png

i was delighted to get yur response! however i was not able to duplicate yur 2nd routine(program) - i presume you wrote it in prime 3 - i also tried on prime 2 with no success - my problem is that i cannot enter R[tot](M) as you did - what may be my problem?

joe lopez wrote:

i was delighted to get yur response! however i was not able to duplicate yur 2nd routine(program) - i presume you wrote it in prime 3

Correct. We can't tell from the file extension which version of Prime a file stems from. Unfortunately PTC provides no way to convert/save a P3 file in P2 format - incredible, but true. Opening a P3 file with P2 will result in just an empty worksheet. From your profile I see you are under maintainance. so I guess you should be entitled to upgrade to P3, I guess.

Generally its a good idea to state which version of Mathcad a question is related to.

my problem is that i cannot enter R[tot](M) as you did - what may be my problem?

I cant't tell from your description what your problem could be as you didn't state what you tried and what did not work in which way. You have to use the programming menu to enter that function definition. Being under maintainance you don't use Prime Express, I think, otherwise programming would not be allowed.

Find attached the vital parts redone in Prime2 format and also a pdf of the original document (but I think my screenshots covered all anyway).

The variable ORIGIN used in my original sheet was just to ensure that the routine would work even if you intend to change that system variable to something else. If you leave it at the default zero you may do it as in the attached P2 file.

temp.png

Top Tags