pub struct MatlabMatrix {
pub rows: Vec<Vec<MatlabExpr>>,
}Expand description
A MATLAB matrix literal.
Fields§
§rows: Vec<Vec<MatlabExpr>>Rows of the matrix (each row is a list of expressions).
Implementations§
Source§impl MatlabMatrix
impl MatlabMatrix
Sourcepub fn add_row(self, row: Vec<MatlabExpr>) -> Self
pub fn add_row(self, row: Vec<MatlabExpr>) -> Self
Add a row to the matrix.
Sourcepub fn identity(n: usize) -> MatlabExpr
pub fn identity(n: usize) -> MatlabExpr
Create an identity matrix of size n.
Sourcepub fn zeros(m: usize, n: usize) -> MatlabExpr
pub fn zeros(m: usize, n: usize) -> MatlabExpr
Create a zeros matrix of shape (m, n).
Sourcepub fn ones(m: usize, n: usize) -> MatlabExpr
pub fn ones(m: usize, n: usize) -> MatlabExpr
Create an ones matrix of shape (m, n).
Trait Implementations§
Source§impl Clone for MatlabMatrix
impl Clone for MatlabMatrix
Source§fn clone(&self) -> MatlabMatrix
fn clone(&self) -> MatlabMatrix
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 Debug for MatlabMatrix
impl Debug for MatlabMatrix
Source§impl Default for MatlabMatrix
impl Default for MatlabMatrix
Source§impl PartialEq for MatlabMatrix
impl PartialEq for MatlabMatrix
impl StructuralPartialEq for MatlabMatrix
Auto Trait Implementations§
impl Freeze for MatlabMatrix
impl RefUnwindSafe for MatlabMatrix
impl Send for MatlabMatrix
impl Sync for MatlabMatrix
impl Unpin for MatlabMatrix
impl UnsafeUnpin for MatlabMatrix
impl UnwindSafe for MatlabMatrix
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