Wow, that is slow. Well java's pow function uses floats on the exponent so it would be a lot faster if you used a temporary variable, and then multiplied it by its self.  Other than that I don't know, most of these math functions should translate to a single ASM function so I don't know why it's that slow.<p>PS: I would probably inline the C function, but that's not a huge deal.  My point was each language has its own optimizations; the only way to compare them is to write reasonably optimized programs in each of them and compare that.<p>Edit: I think Java's sin functions are slower than the HW implementation but more accurate, which is irrelevant because you don't care but it's something to look into.  I dislike Java for other reasons, but it's easy to make code slow which code that looks very similar runs a lot faster.