This PTC Mathcad Prime 9 worksheet uses a simple physics problem to provide introductory information on some important fundamentals of Mathcad. The principles covered in this worksheet are at the core of using Mathcad, and should be helpful for those who are new to Mathcad and just getting started.
Please note that this is not intended to be an in-depth tutorial, and therefore won't provide details on every mouse click and keyboard entry. There are tutorials available in the Getting Started tab on the ribbon, so if you find yourself needing a little extra explanation, the tutorials would be a good resource.
Check the following directories.
For regular Mathcad version: C:\Program Files\Mathcad\Mathcad 15
And Mathcad Prime version: C:\Program Files\PTC\Mathcad Prime
In this example, F(m) was defined. Then later a vector was created F(mass). How did the program understand that m = mass, too? It looked inconsistent to me.
"It looked inconsistent to me." It isn't.
defines a function F, with a 'formal' or dummy parameter m. You should realise that this m has NOTHING to do with the m that appears in the definition of the variable F:
a little earlier in the example. Because this is a definition of a variable in terms of other variables, all these variables (m, v0,d , g and theta) must be defined prior to the definition of the variable F. Well g is a predefined constant in Prime. The other variables are defined explicitly in the sheet.
But now F is (essentially re-)defined as a function, with only one dummy parameter: m. The other variables in the function definition must still be defined prior to that definition.
When calling the function F you can fill in any value (or variable name) for m. As an example:
If you've defined the variable m3 as:
you can use it:
The example defines an array of mass values, with the variable name mass:
then the result of calling F with that variable is:
And because a variable m is also (still) predefined, you can also get:
(So this is where the function F is called with variable m as value for its formal parameter m.)
You should also note that, because the variable F was redefined to a function F, you can no longer evaluate the variable F (to the right of, and below the definition of the function F). If you try to evaluate the variable F below the definition of the function you get:
Which indicates that F should be treated as a function with one formal parameter (Prime expects a variable or value as the parameter to that function).
Hope this helps to clarify.