pub struct DAEStructure<F: Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> {
pub n_differential: usize,
pub n_algebraic: usize,
pub n_diff_eqs: usize,
pub n_alg_eqs: usize,
pub index: DAEIndex,
pub diff_index: usize,
pub constraint_jacobian: Option<Array2<F>>,
pub derivative_jacobian: Option<Array2<F>>,
pub incidence_matrix: Option<Array2<bool>>,
pub variable_dependencies: Option<Vec<Vec<usize>>>,
pub equation_dependencies: Option<Vec<Vec<usize>>>,
}Expand description
Index structure of a DAE system
Fields§
§n_differential: usizeNumber of differential variables
n_algebraic: usizeNumber of algebraic variables
n_diff_eqs: usizeNumber of differential equations
n_alg_eqs: usizeNumber of algebraic equations
index: DAEIndexIndex of the DAE system
diff_index: usizeDifferentiation index (number of differentiations needed to reach an ODE)
constraint_jacobian: Option<Array2<F>>Jacobian of the constraint equations with respect to algebraic variables
derivative_jacobian: Option<Array2<F>>Jacobian of the constraint equations with respect to derivatives
incidence_matrix: Option<Array2<bool>>Incidence matrix showing dependencies between equations and variables
variable_dependencies: Option<Vec<Vec<usize>>>Variables that appear in each equation with non-zero coefficients
equation_dependencies: Option<Vec<Vec<usize>>>Equations in which each variable appears with non-zero coefficients
Implementations§
Source§impl<F: Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> DAEStructure<F>
impl<F: Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> DAEStructure<F>
Sourcepub fn new_semi_explicit(n_differential: usize, nalgebraic: usize) -> Self
pub fn new_semi_explicit(n_differential: usize, nalgebraic: usize) -> Self
Create a new DAE structure for a semi-explicit system
Sourcepub fn new_fully_implicit(n_equations: usize, nvariables: usize) -> Self
pub fn new_fully_implicit(n_equations: usize, nvariables: usize) -> Self
Create a new DAE structure for a fully implicit system
Sourcepub fn compute_index<FFunc, GFunc>(
&mut self,
t: F,
x: ArrayView1<'_, F>,
y: ArrayView1<'_, F>,
f: &FFunc,
g: &GFunc,
) -> IntegrateResult<DAEIndex>where
FFunc: Fn(F, ArrayView1<'_, F>, ArrayView1<'_, F>) -> Array1<F>,
GFunc: Fn(F, ArrayView1<'_, F>, ArrayView1<'_, F>) -> Array1<F>,
pub fn compute_index<FFunc, GFunc>(
&mut self,
t: F,
x: ArrayView1<'_, F>,
y: ArrayView1<'_, F>,
f: &FFunc,
g: &GFunc,
) -> IntegrateResult<DAEIndex>where
FFunc: Fn(F, ArrayView1<'_, F>, ArrayView1<'_, F>) -> Array1<F>,
GFunc: Fn(F, ArrayView1<'_, F>, ArrayView1<'_, F>) -> Array1<F>,
Compute the index of the DAE system
Trait Implementations§
Source§impl<F: Clone + Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Clone for DAEStructure<F>
impl<F: Clone + Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Clone for DAEStructure<F>
Source§fn clone(&self) -> DAEStructure<F>
fn clone(&self) -> DAEStructure<F>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<F: Debug + Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Debug for DAEStructure<F>
impl<F: Debug + Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Debug for DAEStructure<F>
Source§impl<F: Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Default for DAEStructure<F>
impl<F: Float + FromPrimitive + Debug + ScalarOperand + AddAssign + SubAssign + MulAssign + DivAssign + Display + LowerExp + Sum + IntegrateFloat> Default for DAEStructure<F>
Auto Trait Implementations§
impl<F> Freeze for DAEStructure<F>
impl<F> RefUnwindSafe for DAEStructure<F>where
F: RefUnwindSafe,
impl<F> Send for DAEStructure<F>where
F: Send,
impl<F> Sync for DAEStructure<F>where
F: Sync,
impl<F> Unpin for DAEStructure<F>
impl<F> UnwindSafe for DAEStructure<F>where
F: RefUnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more