alfcen Well-Known Member Licensed User Longtime User Jan 25, 2011 #1 For curiosity, how much slower is for instance sinD(x) compared with sin(x)?
derez Expert Licensed User Longtime User Jan 25, 2011 #2 factor = cPi / 180 sinD(x) = sin( x * factor ) so how much slower can it be ? Upvote 0
alfcen Well-Known Member Licensed User Longtime User Jan 25, 2011 #3 So one may assume. However, not sure how angular values are processed internally. Long ago, I used GFA-BASIC (now ancient history), which provided sinD(x), etc., but was about 10 times slower. Upvote 0
So one may assume. However, not sure how angular values are processed internally. Long ago, I used GFA-BASIC (now ancient history), which provided sinD(x), etc., but was about 10 times slower.
Erel B4X founder Staff member Licensed User Longtime User Jan 25, 2011 #4 factor = cPi / 180 sinD(x) = sin( x * factor ) Click to expand... This is exactly the code. Upvote 0
alfcen Well-Known Member Licensed User Longtime User Jan 25, 2011 #5 Sure it is, but the question is: which function executes faster, sinD(angular) or sin(radians)? Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Jan 25, 2011 #6 sinD calls sin. It is a little bit slower as it first multiplies the value. I don't think that you will see any difference between the two. Upvote 0
sinD calls sin. It is a little bit slower as it first multiplies the value. I don't think that you will see any difference between the two.
alfcen Well-Known Member Licensed User Longtime User Jan 25, 2011 #7 Thank you very much Erel, that answers the question. Upvote 0