solve_adaptive

Function solve_adaptive 

Source
pub fn solve_adaptive<F>(
    f: F,
    x0: f64,
    y0: f64,
    x_end: f64,
    initial_step: f64,
    config: AdaptiveConfig,
) -> Result<Vec<(f64, f64)>, ODEError>
where F: Fn(f64, f64) -> f64,
Expand description

Solves a first-order ODE using adaptive RKF45 method with Result type

§Arguments

  • f - The derivative function f(x, y)
  • x0 - Initial x value
  • y0 - Initial y value
  • x_end - Final x value
  • initial_step - Initial step size
  • config - Adaptive configuration

§Returns

Result containing vector of (x, y) solution points