Skip to content

Commit 49ae0ea

Browse files
committed
Update RiemannIntegration.java
i'll deal with formatting later
1 parent 36ae92c commit 49ae0ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/thealgorithms/maths/RiemannIntegration.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public static void main(String[] args) {
8686
*/
8787
public static final void example() {
8888
final Function < Double, Double > xSquaredFunction = x -> Math.pow(x, 2); // Creates the function f(x) = x^2
89-
final double result = RiemannIntegration.trapezoidalRiemannSum (xSquaredFunction, 0, 1, 9); // I find that an accuracy between 7 - 10 (inclusive) works best.
89+
double result = RiemannIntegration.trapezoidalRiemannSum (xSquaredFunction, 0, 1, 9); // I find that an accuracy between 7 - 10 (inclusive) works best.
9090
System.out.println ("Integral of y = x^2 from x = 0 to x = 1: " + result);
9191
}
9292
}

0 commit comments

Comments
 (0)