Hey everyone,
What is Math.E and how can it be used? I've heard it has something to do with "logarithms" but I'm not quite sure what that is either.
Many thanks,
Alex.
Welcome to the Java Programming Forums
The professional, friendly Java community. 21,500 members and growing!
The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.
>> REGISTER NOW TO START POSTING
Members have full access to the forums. Advertisements are removed for registered users.
Hey everyone,
What is Math.E and how can it be used? I've heard it has something to do with "logarithms" but I'm not quite sure what that is either.
Many thanks,
Alex.
This is a constant value that is stored in the Math class;
Example: the PI is also a standart constant look references to math constants
Maybe your looking for the exponent method ?class Math { static double E = 2.718...; static double PI = 3.141596535...; }
Here are methods that are int the Math class with description:
abs(type a) – returns the absolute value of the type(double, float, long, int)
exp(double exponent) – e^exponent. Returns double
sqrt(double a) – returns the square root of the given double
log(double a) – returns the natural log of a
log10(double a) – returns the base 10 log of a
ceil(double a) – rounds up to the nearest whole int
floor(double a) – rounds down to the nearest whole int
pow(double base, double exponent) – guess what this does? Yep, raises the base to the exponent
RedCloudTsunami (July 10th, 2012)