pub struct Grid<const N: usize> {
pub min: [f64; N],
pub dx: [f64; N],
pub tensor_info: Tensor<N>,
}Expand description
Represents a N-dimensional Cartesian discretization grid.
Contains parameters for converting between discrete indices and continuous state space values.
§Fields
min- The lower bound coordinate for each dimension.dx- The step size for each dimension: $(Max - Min) / (Shape - 1)$.tensor_info- Underlying tensor structure holding topology (shape, strides) but not necessarily data values.
Fields§
§min: [f64; N]§dx: [f64; N]§tensor_info: Tensor<N>Implementations§
Auto Trait Implementations§
impl<const N: usize> Freeze for Grid<N>
impl<const N: usize> RefUnwindSafe for Grid<N>
impl<const N: usize> Send for Grid<N>
impl<const N: usize> Sync for Grid<N>
impl<const N: usize> Unpin for Grid<N>
impl<const N: usize> UnsafeUnpin for Grid<N>
impl<const N: usize> UnwindSafe for Grid<N>
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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