extern crate maths_traits;
extern crate numerical_integration;
use numerical_integration::*;
use maths_traits::analysis::metric::InnerProductMetric;
fn main() {
fn f(_t: f64, y: f64) -> f64 { y }
let ds = 0.5;
let mut s4 = DORMAND_PRINCE.adaptive_init(0.0, 1.0, ds, &f, InnerProductMetric);
for _ in 0..100 {
let (t, y) = DORMAND_PRINCE.adaptive_step(s4.as_mut(), ds, &f, InnerProductMetric);
println!("t={} y={} exp(t)={}", t, y, t.exp());
}
}