# Class MatrixNTI2D<V>

data-structure-typed

#### Author

Tyler Zeng

#### Copyright

Copyright (c) 2022 Tyler Zeng zrwusa@gmail.com

#### License

MIT License

#### Type Parameters

- #### V = any

#### Hierarchy

- MatrixNTI2D

- Defined in src/data-structures/matrix/matrix.ts:9

#####
Index

### Constructors

constructor

### Properties

_matrix

### Methods

toArray

## Constructors

### constructor

- new MatrixNTI2D<V>(options): MatrixNTI2D<V>

- The constructor creates a matrix with the specified number of rows and columns, and initializes all elements to a given initial value or 0 if not provided.

  #### Type Parameters

  - #### V = any

  #### Parameters

  - ##### options: {
    col: number;
    initialVal?: V;
    row: number;
    }

    An object containing the following properties:

    - ##### col: number

    - ##### `Optional` initialVal?: V

    - ##### row: number

  #### Returns MatrixNTI2D<V>

  - Defined in src/data-structures/matrix/matrix.ts:17

## Properties

### `Private` `Readonly` _matrix

_matrix: V[][]

- Defined in src/data-structures/matrix/matrix.ts:10

## Methods

### toArray

- toArray(): V[][]

- #### Returns V[][]

  - Defined in src/data-structures/matrix/matrix.ts:24

Generated using TypeDoc