use crate::algorithm::two_phase::matrix_provider::column::Column;
use crate::algorithm::two_phase::matrix_provider::MatrixProvider;
use crate::algorithm::two_phase::tableau::inverse_maintenance::InverseMaintainer;
use crate::algorithm::two_phase::tableau::inverse_maintenance::ops as im_ops;
use crate::algorithm::two_phase::tableau::kind::artificial::Cost as ArtificialCost;
use crate::data::linear_algebra::vector::SparseVector;
pub mod two_phase;
pub trait SolveRelaxation: MatrixProvider {
fn solve_relaxation<'provider, IM>(&'provider self) -> OptimizationResult<IM::F>
where
IM: InverseMaintainer<F:
im_ops::FieldHR +
im_ops::Column<<Self::Column as Column>::F> +
im_ops::Cost<ArtificialCost> +
im_ops::Cost<Self::Cost<'provider>> +
im_ops::Rhs<Self::Rhs> +
im_ops::Column<Self::Rhs> +
>,
;
}
#[allow(missing_docs)]
#[derive(Eq, PartialEq, Debug)]
pub enum OptimizationResult<F> {
Infeasible,
FiniteOptimum(SparseVector<F, F>),
Unbounded,
}