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

Community email notifications are disrupted. While we are working to resolve, please check on your favorite boards regularly to keep up with your conversations and new topics.

trigonometric equation formating

DU_8998062
3-Visitor

trigonometric equation formating

Can anyone tell me the correct syntax for using trigonometric functions?  When I try it, I get an error result that says "missing term or expression".  All help appreciated

14 REPLIES 14

1. What version of the program are you using?

2. Please show your example.

Hi,

Like this:

Capture.JPG

My equations look just like yours except instead of an answer of 0.7071, I get an error message "missing term or expression"

As you do not show what you are actually trying we have to stab in the dark 😞

The error message you mention is thrown when you don't provide a function argument (by default you would see a question mark instead of the three dots)

Werner_E_1-1675951843845.png

But as this is very obvious I guess that's not the problem which you experience.

So for sure you would need to show examples of what you are doing and it also may help if you state which kind of Mathcad you are using (real, legacy Mathcad 15 or below or Prime) and which version.

 

The error message comes after the equal sign. It looks just like your bottom equation but instead of giving the answer of 0.5, it gives the error message. I am using Prime 8.0

Can you post the failing worksheet or at least a screenshot!?
Have you tried what I show in the second line (pi/6) with the same error?

Have you tried too use the unit "deg" instead of "°" as seen in Terrys answer. You may explicitly type a multiplication after the number as Terry did, but it should not be necessary, just type "deg" after the number. That way you won't see a dot between the two

Werner_E_0-1675983589977.png

Are the letters "sin" upright or italic? When you click somewhere in "sin" and then look at menu Math-Style-Label, do you see "Function" as in the screenshot below or something else? If something else, does it help when you manually change the label to "Function"? Changing it to "Automatic" should work as well.

Werner_E_0-1675984354847.png

Actually I don't think that wrong labelling is the cause as the error message would be something else ("variable undefined") if that would be the case, but without seeing what you actually typed and without being able to play around with your worksheet we still are just stabbing in the dark 😞

 

You sure have typed the normal equal sign and not the fat boolean one which you get with Ctrl-+ !? Guess that could not be the cause, either, as if you use the boolean equal you won't get any error message - Prime would just wait for you to type in the RHS of the equation and tell it what you want to be done with the equation.

 

When you are using the inverse sinus (arcsin, in Prime called asin) and want to see the result in degree rather than the default radian, you unfortunately can't simply type "°" as we can do in real Mathcad. In Prime we get the exact error message you experience. You either have to type "deg" in the unit placeholder or uncomfortably chose the unit degree from the units menu.

Werner_E_1-1675984725831.png

But then you sure did not want the result of the sine function to be displayed in degree as the result isn't an angle anyway.

 

So again just a lot of shots in the dark...

 

Do you experience any problems with the attached worksheet?
It sure will look OK when you just open it as all you see is the last view I had over here. You should let the sheet recalculate (F9 or F5) to see what your installation of Prime thinks of it.

I am using Prime 6 but I don't think that such a severe bug could have found its way in P8 an remained undetected until now.

Here is what you should see, also after recalculation:

Werner_E_0-1675985731299.png

 

And one last try: You didn't do this (putting the angle outside of the parentheses), didn't you?

Werner_E_0-1675985980666.png

 

upload_-aW1hZ2UucG5n-8914008384735128273..png
Here is what I am getting. As you can see, I tried your suggestion regarding the sin(30 deg) without the multiplier dot included and got the one on the top left.

Hi,

There are three equals signs in Prime each one is different

:=  assignment equals

= output equals

= equivalence

 

 

Capture.JPG

Well okay then. I only know of the one equal sign, :=. How do you incorporate the other types of equal signs? What keys?

It really would  have helped if you had attached your worksheet as well!

 


@DU_8998062 wrote:
Well okay then. I only know of the one equal sign, :=. How do you incorporate the other types of equal signs? What keys?


Actually there are two more "equal signs" additionally to the three mentioned by Terry - the symbolic evaluation and the global definition.

But you seem to know already at least of two different equal signs as we see that you had used them in your picture (and they sure are the most important two equal signs you should know of).

Obviously you used the "normal" equal sign (numeric evaluation) when you got the correct result for sin (30 deg).

Werner_E_0-1675991555319.png

And you used the assignment/definition equal (which you get by simply typing a colon ":")  when you assigned the value 45 deg to phi and theta.

Werner_E_1-1675991586969.png

In all expressions which failed I see an assignment := instead of an evaluation =.
Did you type this? if so, than thats the culprit.
You have to type just a normal equal sign to numerically evaluate an expression.

Example:

Werner_E_2-1675992021807.png

The first region is an assignment/definiton (note the colon ":") - the variable phi is assigned the value pi/6; the variable is defined. And the last two regions are numeric evaluations (note that there is NO colon here!)
See also
https://support.ptc.com/help/mathcad/r8.0/en/index.html#page/PTC_Mathcad_Help/evaluation_operator.html

or

https://support.ptc.com/help/mathcad/r8.0/en/index.html#page/PTC_Mathcad_Help/using_the_definition_and_evaluation_operators.html#wwID0E1ZOR

or

https://support.ptc.com/help/mathcad/r8.0/en/index.html#page/PTC_Mathcad_Help/about_evaluating_math_expressions.html#wwID0EMLEQ

 

BTW, as you already had success with sin(30 deg). It should work as well if you type an explicit multiplication and it should also work using the degree sign. It really looks to me that you always used the assignment definition := instead of the evaluation =

You also have not answered my question if you experienced any problems with the file I had attached when you let prime recalculate it!

 

 

:= assignment equals - [Shift]Colon: buttons

= output equals - Equal button

= equivalence - [Ctrl]Equal buttons

 

Actually buttons/keyboard shortcuts depend on which language keyboard you are using.
E.g. on my german keyboard I get the boolean equal with "Ctrl +" and not with "Ctrl =".

 

The localized help should be of help, but unfortunately isn't.

The German help for P6 claims that there is no keyboard shortcut for the boolean equivalence and the German P8 help claims that the shortcut is Ctrl =, which is true for English language keyboards but not for German ones.
There are quite some other discrepancies, too - localization was done very sloppily (and I am not surprised about that).

 

ppal
17-Peridot
(To:DU_8998062)

Mine works fine. Please see file which I have not attached.

Werner_E
24-Ruby V
(To:ppal)


@ppal wrote:

Mine works fine. Please see file which I have not attached.


Your file contained a small clerical error. I have corrected it in the file not attached here.

Top Tags