jQuery in Action, 2nd edition*
The moose likes Beginning Java and the fly likes Mathematic function? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Mathematic function?" Watch "Mathematic function?" New topic

Mathematic function?

sahar sa
Ranch Hand

Joined: Jul 06, 2009
Posts: 102
Dear friends,
I need to code a formula which contains Natural logarithm and "e" power 3 for example. by e I mean the transcendental number which is around 2.71 ... .
Is there any constant in java as "e" or no?
Is there any function that can calculates Ln (natural logarithm)?
do you know any source that can help me?
Thank you so much,
Henry Wong

Joined: Sep 28, 2004
Posts: 18552




Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
Jelle Klap

Joined: Mar 10, 2008
Posts: 1756

Have a look at java.lang.Math.

Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life.
David Newton

Joined: Sep 29, 2008
Posts: 12617

And if there wasn't already such a thing, just *type it in* and set it to a variable.
I agree. Here's the link: http://aspose.com/file-tools
subject: Mathematic function?
Similar Threads
For Loop Performance
Sort the Array in reverse order
How to calculate log values of base 2
Rasing BigDecimal to a power
To calculate 9th root of any number without using build in function