use of java.math.MathContext in project big-math by eobermuhlner.
the class FunctionTable method printTableAcos.
public static void printTableAcos() {
MathContext mathContext = new MathContext(20);
printTable(-1, 1, 0.01, Arrays.asList("BigDecimalMath.acos", "Math.acos"), Arrays.asList(x -> BigDecimalMath.acos(x, mathContext), x -> BigDecimal.valueOf(Math.acos(x.doubleValue()))));
}
use of java.math.MathContext in project big-math by eobermuhlner.
the class FunctionTable method printTableLog.
public static void printTableLog() {
MathContext mathContext = new MathContext(20);
printTable(0, 10, 0.1, Arrays.asList("BigDecimalMath.log", "Math.log"), Arrays.asList(x -> BigDecimalMath.log(x, mathContext), x -> BigDecimal.valueOf(Math.log(x.doubleValue()))));
}
use of java.math.MathContext in project big-math by eobermuhlner.
the class FunctionTable method printTableExp.
public static void printTableExp() {
MathContext mathContext = new MathContext(20);
printTable(0, 10, 0.1, Arrays.asList("BigDecimalMath.exp", "Math.exp"), Arrays.asList(x -> BigDecimalMath.exp(x, mathContext), x -> BigDecimal.valueOf(Math.exp(x.doubleValue()))));
}
use of java.math.MathContext in project big-math by eobermuhlner.
the class FunctionTable method printTableAtan.
public static void printTableAtan() {
MathContext mathContext = new MathContext(20);
printTable(-1, 1, 0.01, Arrays.asList("BigDecimalMath.atan", "Math.atan"), Arrays.asList(x -> BigDecimalMath.atan(x, mathContext), x -> BigDecimal.valueOf(Math.atan(x.doubleValue()))));
}
use of java.math.MathContext in project big-math by eobermuhlner.
the class FunctionTable method printTableLog10.
public static void printTableLog10() {
MathContext mathContext = new MathContext(5);
printTable(0, 100, 1, Arrays.asList("BigDecimalMath.log10", "Math.log10"), Arrays.asList(x -> BigDecimalMath.log10(x, mathContext), x -> BigDecimal.valueOf(Math.log(x.doubleValue()) / Math.log(10))));
}
Aggregations