pub struct QuadResult<T: Float> {
pub value: T,
pub error_estimate: T,
pub n_evals: usize,
}Expand description
Result of a numerical integration.
§Examples
let result = simpson(|x: f64| x * x, 0.0, 1.0, 100).unwrap();
assert!((result.value - 1.0 / 3.0).abs() < 1e-6);Fields§
§value: TThe estimated value of the integral.
error_estimate: TAn estimate of the absolute error.
n_evals: usizeNumber of function evaluations.
Trait Implementations§
Source§impl<T: Clone + Float> Clone for QuadResult<T>
impl<T: Clone + Float> Clone for QuadResult<T>
Source§fn clone(&self) -> QuadResult<T>
fn clone(&self) -> QuadResult<T>
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 moreAuto Trait Implementations§
impl<T> Freeze for QuadResult<T>where
T: Freeze,
impl<T> RefUnwindSafe for QuadResult<T>where
T: RefUnwindSafe,
impl<T> Send for QuadResult<T>
impl<T> Sync for QuadResult<T>
impl<T> Unpin for QuadResult<T>where
T: Unpin,
impl<T> UnsafeUnpin for QuadResult<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for QuadResult<T>where
T: UnwindSafe,
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