changed function and integral

This commit is contained in:
2024-06-02 14:40:51 +02:00
parent 91fad47f31
commit 5ed2bfa730

View File

@@ -21,11 +21,10 @@ const SAMPLES_PER_ITERATION: usize = 250;
fn f(x: f64) -> f64 {
E.powf(x) * (1.0 / x.sin()).cos() + x.powf(2.0)
//E.powf(-x) * x.tan() * (2.0 / (2.0 * x).sin()).cos() + 1.0
}
fn main() {
let bounds: Bounds = Bounds::new(LinearBounds::new(-1_f64, 1_f64), LinearBounds::new(0_f64, 10_f64));
let bounds: Bounds = Bounds::new(LinearBounds::new(3.1_f64, 3.2_f64), LinearBounds::new(0_f64, 10_f64));
let func: Function = Function::new(f);
let start: Instant = Instant::now();