.
This commit is contained in:
@@ -122,15 +122,12 @@ public class IntegralCalculator {
|
||||
currentStart = end;
|
||||
|
||||
futures.add(executor.submit(() -> {
|
||||
var prevSteps = 0;
|
||||
var steps = 0;
|
||||
var partitionSum = 0.0;
|
||||
for (var j = start; j < end; j++) {
|
||||
partitionSum += function.apply(lowerBound + h * j);
|
||||
steps++;
|
||||
|
||||
var progress = total.incrementAndGet();
|
||||
progressCallback.accept(progress, n);
|
||||
this.callProgressCallback(progress, n);
|
||||
}
|
||||
|
||||
return partitionSum;
|
||||
|
||||
Reference in New Issue
Block a user