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

SOLVED
1-Newbie

## Range Variables Question

I'm having an issue with the following and any help would be much appreciated

Lets say I have a key frequency of interest

All of the following MATHCAD code has been generated

Input Parameter:

KeyFreq=1

Output(KeyFreq)=| 0

| 10 if KeyFreq > 5

Output(KeyFreq)= 0

Now my queston is the following:

I want to find out what the Output(KeyFreq) becomes from a KeyFreq range of 1-100

I tried using the "KeyFreq=1...100", however this won't output the data.

1 ACCEPTED SOLUTION

Accepted Solutions
 dan nguyen wrote:I'm having an issue with the following and any help would be much appreciatedLets say I have a key frequency of interestAll of the following MATHCAD code has been generatedInput Parameter:KeyFreq=1Output(KeyFreq)=| 0 | 10 if KeyFreq > 5 Output(KeyFreq)= 0Now my queston is the following:I want to find out what the Output(KeyFreq) becomes from a KeyFreq range of 1-100I tried using the "KeyFreq=1...100", however this won't output the data.Thanks for your assistance!

You've probably found the solution by now, but just in case it's of any help ... see attached.

Stuart

4 REPLIES 4
4-Participant
(To:ptc-4531061)

Mike

 dan nguyen wrote:I'm having an issue with the following and any help would be much appreciatedLets say I have a key frequency of interestAll of the following MATHCAD code has been generatedInput Parameter:KeyFreq=1Output(KeyFreq)=| 0 | 10 if KeyFreq > 5 Output(KeyFreq)= 0Now my queston is the following:I want to find out what the Output(KeyFreq) becomes from a KeyFreq range of 1-100I tried using the "KeyFreq=1...100", however this won't output the data.Thanks for your assistance!

You've probably found the solution by now, but just in case it's of any help ... see attached.

Stuart

1-Newbie
(To:StuartBruff)

Thanks Stuart_Bruff,

Unfortunately I had to do the solve the problem by punching in each key frequency and seeing the output. But I do appreciate your assistance in the matter! For future analysis, is it possible to export the vector data into a table? For instance in the your attached mathcad sheet, the output was (0 0 0 0 10 10 10 10 10) for a range from 0 to 9.

Would it be possible to display the information as key frequency in a column of a table and the output in the other column as seen below

KeyFreq | Output

0 | 0

1 | 0

.

.

.

9 | 10

I've been tinkering with the table function in MATHcad however it's not working out as well (due to my own self admitted ignorance).

best,

Dan

 dan nguyen wrote:Unfortunately I had to do the solve the problem by punching in each key frequency and seeing the output. But I do appreciate your assistance in the matter! For future analysis, is it possible to export the vector data into a table? For instance in the your attached mathcad sheet, the output was (0 0 0 0 10 10 10 10 10) for a range from 0 to 9. Would it be possible to display the information as key frequency in a column of a table and the output in the other column as seen belowKeyFreq | Output0 | 01 | 0 . . .9 | 10I've been tinkering with the table function in MATHcad however it's not working out as well (due to my own self admitted ignorance).

The simplest way is to use augment and stack to join the data together as in the attached example. I've shown 2 choices of array result, matrix and table. Double click on an array result to bring up the 'Result Format' dialog and choose whichever option you prefer from the 'Display Options' tab. If you choose table format, the right-clicking on the table and choosing 'Properties' will allow you to choose the font and whether or not to display the row/col labels.