Math. Coding???
6 posts • Page 1 of 1
Math. Coding???
I still have no clue what math. is used for. Like what are the uses of this i have seen it in many scenes like RA2Lovers mouse pointer. What is Math. used for i have scene math.round, math.atan, etc.
-
niffirg1 - Posts: 376
- Joined: Mon Aug 31, 2009 10:31 pm
- Location: The Great American South!
Re: Math. Coding???
math.* are math functions like sine, cosine, tangent, multiply, divide, ...
for example "math.multiply(3,4)" is similar to 3*4
"math.sin(3)" will give the value of sin(3). in algodoo you also can write "sin(3)" instead of "math.sin(3)"
btw. atan is the inverse function for tan. it's used to calculate angles. that's no invention of thyme, it has something to do with trigonometric functions.
in phun those functions are just with "math." in front of them because you can tell the math functions apart from other function types like "scene.", "sim." etc. more easy.
for example "math.multiply(3,4)" is similar to 3*4
"math.sin(3)" will give the value of sin(3). in algodoo you also can write "sin(3)" instead of "math.sin(3)"
btw. atan is the inverse function for tan. it's used to calculate angles. that's no invention of thyme, it has something to do with trigonometric functions.
in phun those functions are just with "math." in front of them because you can tell the math functions apart from other function types like "scene.", "sim." etc. more easy.
-
KarateBrot - Posts: 825
- Joined: Mon Aug 31, 2009 7:32 pm
- Location: Germany
Re: Math. Coding???
Oh i know trigonometry or at least the cos, tan and sin and the inverses of the three i just did not know how to use math coding
-
niffirg1 - Posts: 376
- Joined: Mon Aug 31, 2009 10:31 pm
- Location: The Great American South!
Re: Math. Coding???
but is math.atan the same as tan-1 ? tan-1 means tan and than the -1 is smal.... like squire 2 ( i can't type it is this box )
- jessebax129
- Posts: 34
- Joined: Tue Jan 05, 2010 6:32 pm
Re: Math. Coding???
tan^-1(x) = arctangent(x) = math.atan(x).
Jrv wrote:TC42 wrote:Quite honestly, I didn't think anyone on 4chan has that good a use of grammar, spelling, usage, mechanics, ect.
But I've never been there, so I may be wrong.
GTFO newfgt
-
RA2lover - Posts: 607
- Joined: Mon Aug 31, 2009 8:43 pm
- Location: Brazil
Re: Math. Coding???
jessebax129 wrote:but is math.atan the same as tan-1 ? tan-1 means tan and than the -1 is smal.... like squire 2 ( i can't type it is this box )
he meant tan^(-1). but that doesn't mean "tan to the power of -1" because that would be 1/tan. for inverse functions ^(-1) is used very often to mark them as those. and the inverse function for tan is the arc tangent. it looks like a part of the tangent put rotated about 90°.
and yes, atan is the same as tan^(-1) if tan^(-1) means the inverse function of tan.
-
KarateBrot - Posts: 825
- Joined: Mon Aug 31, 2009 7:32 pm
- Location: Germany
6 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 9 guests