Link
Link

Reputation: 81

Pure java implementation of the java.lang.Math class

I just downloaded the openjdk source and came to the realization that nearly all of the java.lang.Math class was implemented in native c/c++ code. I was wondering if there were any implementations that were fully written in java.

Upvotes: 8

Views: 1278

Answers (2)

axelclk
axelclk

Reputation: 958

Currently some pure Java improvements for methods in the java.lang.Math class are integrated into apache commons-math:

See: Elementary functions in JDK are slower than necessary and not as accurate as they could be.

Upvotes: 3

kgiannakakis
kgiannakakis

Reputation: 104196

Have a look at MicroFloat. It targets J2ME platform and according to the author it implements all methods in java.lang.Math.

Upvotes: 7

Related Questions