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

Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X

Multi-variable Equations and 3-D Plots

MNM
1-Visitor
1-Visitor

Multi-variable Equations and 3-D Plots

Hello again (still Mathcad 12 user),

I’m trying to generate 3-D plots of three different equations, where the 2nd and 3rd use the 1st .

Each equation is a function of two variables.

I want the 3-D plots to show the value of the equation in ‘z’ and the range of the variables in ‘x’ and ‘y’ (surface plot).

Attached are three files of three different approaches.

  1. Prob 5.10.xmcd
    1. I was able to generate the graph of the first equation, but the second, despite simplification, returns the error message, “This value must be a scalar or an array.” The function is defined properly, as best that I can tell.
  2. Prob 5.10a.xmcd
    1. This builds on a method to find a single vector driven variable given to me by Stuart Bruff.
      [I seem to not be able to get the original to work, despite copying everything required from the original file.]
      The original file name is: solve_block_problem_186_859.mcd at:
      http://communities.ptc.com/message/23151#23151
    2. Even though, I believe, I set the solve block up correctly, when I get to the vectorize part the following error occurs, “This value must be a function.”
  3. Prob 5.10b.xmcd
    1. This uses the vector approach for the variables, but only generates results using η for η for the two variables, thus generates a single curve and not a surface.

How can I achieve my aim of displaying the range of possibilities as a 3-D plot for all equations?

Thank you,

MNM

ACCEPTED SOLUTION

Accepted Solutions
RichardJ
19-Tanzanite
(To:MNM)

Prob 5.10.xmcd
    1. I was able to generate the graph of the first equation, but the second, despite simplification, returns the error message, “This value must be a scalar or an array.” The function is defined properly, as best that I can tell.

If you click on the expression you should notice that there is an implicit multiplication between cos and (theta).

Prob 5.10a.xmcd
    1. This builds on a method to find a single vector driven variable given to me by Stuart Bruff.
      [I seem to not be able to get the original to work, despite copying everything required from the original file.]
      The original file name is: solve_block_problem_186_859.mcd at:
      http://communities.ptc.com/message/23151#23151
    2. Even though, I believe, I set the solve block up correctly, when I get to the vectorize part the following error occurs, “This value must be a function.”

There are several undefined variables. Please define them with realistic values and repost the worksheet.

View solution in original post

5 REPLIES 5
RichardJ
19-Tanzanite
(To:MNM)

Prob 5.10.xmcd
    1. I was able to generate the graph of the first equation, but the second, despite simplification, returns the error message, “This value must be a scalar or an array.” The function is defined properly, as best that I can tell.

If you click on the expression you should notice that there is an implicit multiplication between cos and (theta).

Prob 5.10a.xmcd
    1. This builds on a method to find a single vector driven variable given to me by Stuart Bruff.
      [I seem to not be able to get the original to work, despite copying everything required from the original file.]
      The original file name is: solve_block_problem_186_859.mcd at:
      http://communities.ptc.com/message/23151#23151
    2. Even though, I believe, I set the solve block up correctly, when I get to the vectorize part the following error occurs, “This value must be a function.”

There are several undefined variables. Please define them with realistic values and repost the worksheet.

MNM
1-Visitor
1-Visitor
(To:RichardJ)

Yep,

Once I rewrote the errant cosine function, I was able to move forward along this path.

Thanks, for being there to double check!

When the first errored, I started the other approaches.

They can be forgotten for this problem.

Could a solve Block be used to solve for two variables? If so how?

MNM

RichardJ
19-Tanzanite
(To:MNM)

Could a solve Block be used to solve for two variables? If so how?

Sure. You just need two equations that depend on the variables to be solved for.

MNM
1-Visitor
1-Visitor
(To:MNM)

If you're interested, here is the completed worksheet.

MNM

MNM
1-Visitor
1-Visitor
(To:MNM)

For those REALLY interested, here is the final report.

I'd like to comment, being the originator of this thread, I AM saddened by the turn of it taken by jean Giraud into a rant against Mathcad / PTC..

To him, I suggest he start his own weblog/twitter ccount to do so.

Announcements

Top Tags