Struct Settings

Source
pub struct Settings { /* private fields */ }
Expand description

The settings used when initialising a solver.

Implementations§

Source§

impl Settings

Source

pub fn rho(self, value: f64) -> Settings

Sets the ADMM step rho.

Source

pub fn sigma(self, value: f64) -> Settings

Sets the ADMM step sigma.

Source

pub fn scaling(self, value: Option<u32>) -> Settings

Sets the number of heuristic data scaling iterations.

If None scaling is disabled.

Panics on 32-bit platforms if the value is above i32::max_value().

Source

pub fn adaptive_rho(self, value: bool) -> Settings

Enables choosing rho adaptively.

Source

pub fn adaptive_rho_interval(self, value: Option<u32>) -> Settings

Sets the number of iterations between rho adaptations.

If None it is automatic.

Panics on 32-bit platforms if the value is above i32::max_value().

Source

pub fn adaptive_rho_tolerance(self, value: f64) -> Settings

Sets the tolerance for adapting rho.

The new rho has to be value times larger or 1/value times smaller than the current rho to trigger a new factorization.

Source

pub fn adaptive_rho_fraction(self, value: f64) -> Settings

Set the interval for adapting rho as a fraction of the setup time.

Source

pub fn max_iter(self, value: u32) -> Settings

Sets the maximum number of ADMM iterations.

Panics on 32-bit platforms if the value is above i32::max_value().

Source

pub fn eps_abs(self, value: f64) -> Settings

Sets the absolute convergence tolerance.

Source

pub fn eps_rel(self, value: f64) -> Settings

Sets the relative convergence tolerance.

Source

pub fn eps_prim_inf(self, value: f64) -> Settings

Sets the primal infeasibility tolerance.

Source

pub fn eps_dual_inf(self, value: f64) -> Settings

Sets the dual infeasibility tolerance.

Source

pub fn alpha(self, value: f64) -> Settings

Sets the linear solver relaxation parameter.

Source

pub fn linsys_solver(self, value: LinsysSolver) -> Settings

Sets the linear system solver to use.

Source

pub fn delta(self, value: f64) -> Settings

Sets the polishing regularization parameter.

Source

pub fn polish(self, value: bool) -> Settings

Enables polishing the ADMM solution.

Source

pub fn polish_refine_iter(self, value: u32) -> Settings

Sets the number of iterative refinement steps to use when polishing.

Panics on 32-bit platforms if the value is above i32::max_value().

Source

pub fn verbose(self, value: bool) -> Settings

Enables writing progress to stdout.

Source

pub fn scaled_termination(self, value: bool) -> Settings

Enables scaled termination criteria.

Source

pub fn check_termination(self, value: Option<u32>) -> Settings

Sets the number of ADMM iterations between termination checks.

If None termination checking is disabled.

Panics on 32-bit platforms if the value is above i32::max_value().

Source

pub fn warm_start(self, value: bool) -> Settings

Enables warm starting the primal and dual variables from the previous solution.

Source

pub fn time_limit(self, value: Option<Duration>) -> Settings

Sets the solve time limit.

Trait Implementations§

Source§

impl Clone for Settings

Source§

fn clone(&self) -> Settings

Returns a duplicate of the value. Read more
1.0.0 · Source§

const fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Default for Settings

Source§

fn default() -> Settings

Returns the “default value” for a type. Read more
Source§

impl Send for Settings

Source§

impl Sync for Settings

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.