@@ -13,9 +13,9 @@ This module contains some useful classes and functions for dealing with linear a
13
13
14
14
- constructor(components : list) : init the vector
15
15
- set(components : list) : changes the vector components.
16
- - __ str __ () : toString method
16
+ - \_\_ str \_\_ () : toString method
17
17
- component(i : int): gets the i-th component (start by 0)
18
- - size () : gets the size of the vector (number of components)
18
+ - \_\_ len \_\_ () : gets the size / length of the vector (number of components)
19
19
- euclidLength() : returns the eulidean length of the vector.
20
20
- operator + : vector addition
21
21
- operator - : vector subtraction
@@ -31,12 +31,13 @@ This module contains some useful classes and functions for dealing with linear a
31
31
- computes the axpy operation
32
32
- function randomVector(N,a,b)
33
33
- returns a random vector of size N, with random integer components between 'a' and 'b'.
34
+
34
35
- class Matrix
35
36
- This class represents a matrix of arbitrary size and operations on it.
36
37
37
38
** Overview about the methods:**
38
39
39
- - __ str __ () : returns a string representation
40
+ - \_\_ str \_\_ () : returns a string representation
40
41
- operator * : implements the matrix vector multiplication
41
42
implements the matrix-scalar multiplication.
42
43
- changeComponent(x,y,value) : changes the specified component.
@@ -45,6 +46,7 @@ This module contains some useful classes and functions for dealing with linear a
45
46
- height() : returns the height of the matrix
46
47
- operator + : implements the matrix-addition.
47
48
- operator - _ implements the matrix-subtraction
49
+
48
50
- function squareZeroMatrix(N)
49
51
- returns a square zero-matrix of dimension NxN
50
52
- function randomMatrix(W,H,a,b)
0 commit comments