Quantcast
Channel: PTC Community: Message List - Creo
Viewing all articles
Browse latest Browse all 11377

Trigonometric functions give wrong values if supplied units

$
0
0

I have noticed a rather annoying problem with using Creo parameters with trigonometric functions in relations.

The observed behavior is as follows:

 

(1) Define your parameter with units, for example I define "angle" with a value of 15.0, Unit Quantity of "Angle" and Units of "deg", the result of "tan ( angle )" yields 0.04569. A wrong answer.

(2) Define your parameter with no value for either Unit Quantity or Units, and tan ( angle ) yields 0.267949, which is correct for 15 degrees.

(3) Do a "dumb" evaluation of "tan ( 15.0 )" and you again get 0.267949.

(4) Define your parameter with a value of 15.0, Unit Quantity of "Angle", and Units of "rad", and tan ( angle ) yields 0.267949.

 

So it appears that if you exercise "proper" practice and define your units correctly, you are delivered erroneous results. Put in the wrong units and you get the right answer.

 

Luckily, the error is so different from the correct answer that it is easy to see it's wrong. In this case.

 

Has anyone else observed this behavior?

 

For interest's sake, I'm running Creo 2.0, build M070.


Viewing all articles
Browse latest Browse all 11377

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>