conspire/math/integrate/ode/explicit/
mod.rs1#[cfg(test)]
2mod test;
3
4use crate::{
5 math::{
6 Derivative, Differentiate, Quantity, Tensor, TensorVec,
7 integrate::{IntegrationError, OdeIntegrator, Times},
8 },
9 units::Time,
10};
11
12pub(crate) mod fixed_step;
13pub(crate) mod variable_step;
14
15pub trait Explicit<Y, U, V, T = Time>
17where
18 Self: OdeIntegrator<Y, U>,
19 Y: Differentiate<T> + Tensor,
20 U: TensorVec<Item = Y>,
21 V: TensorVec<Item = Derivative<Y, T>>,
22{
23 const SLOPES: usize;
24 #[doc = include_str!("doc.md")]
25 fn integrate(
26 &self,
27 function: impl FnMut(Quantity<T>, &Y) -> Result<Derivative<Y, T>, String>,
28 time: &[Quantity<T>],
29 initial_condition: Y,
30 ) -> Result<(Times<T>, U, V), IntegrationError>;
31}