Chemical Data Processing Library Python API - Version 1.4.0
Public Member Functions | List of all members
CDPL.Math.FMatrixExpression Class Reference

Represents the outcome of mathematical expressions/operations that result in a matrix. More...

+ Inheritance diagram for CDPL.Math.FMatrixExpression:

Public Member Functions

None swap (FMatrixExpression e)
 Swaps the contents of this matrix expression with those of e. More...
 
FMatrixExpression assign (FMatrixExpression e)
 Assigns the contents of the matrix expression e to this expression. More...
 
FMatrixExpression assign (ConstFMatrixExpression e)
 Assigns the contents of the matrix expression e to this expression. More...
 
FMatrixExpression assign (ConstDMatrixExpression e)
 Assigns the contents of the matrix expression e to this expression. More...
 
FMatrixExpression assign (ConstLMatrixExpression e)
 Assigns the contents of the matrix expression e to this expression. More...
 
FMatrixExpression assign (ConstULMatrixExpression e)
 Assigns the contents of the matrix expression e to this expression. More...
 
None assign (object a)
 Assigns the contents of the 2D numpy.ndarray object a to this matrix expression. More...
 
None setElement (int i, int j, float v)
 Sets the value of the element (i, j) to v. More...
 
None __setitem__ (tuple ij, float v)
 Sets the value of the element (i, j) to v. More...
 
FMatrixExpression __iadd__ (FMatrixExpression e)
 Adds the matrix expression e element-wise to this expression. More...
 
FMatrixExpression __iadd__ (ConstFMatrixExpression e)
 Adds the matrix expression e element-wise to this expression. More...
 
FMatrixExpression __isub__ (FMatrixExpression e)
 Subtracts the matrix expression e element-wise from this expression. More...
 
FMatrixExpression __isub__ (ConstFMatrixExpression e)
 Subtracts the matrix expression e element-wise from this expression. More...
 
FMatrixExpression __imul__ (float t)
 Multiplies every element by the scalar t. More...
 
FMatrixExpression __idiv__ (float t)
 Divides every element by the scalar t. More...
 
FMatrixExpression __itruediv__ (float t)
 Divides every element by the scalar t. More...
 
- Public Member Functions inherited from CDPL.Math.ConstFMatrixExpression
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
int getSize1 ()
 Returns the number of rows. More...
 
int getSize2 ()
 Returns the number of columns. More...
 
bool isEmpty ()
 Tells whether the matrix is empty. More...
 
float getElement (int i, int j)
 Returns the element at (i, j). More...
 
object toArray ()
 Converts the ConstFMatrixExpression instance into a corresponding numpy.ndarray object. More...
 
float __call__ (int i, int j)
 Returns the element at (i, j). More...
 
float __getitem__ (tuple ij)
 Returns the element at (i, j). More...
 
int __len__ ()
 Returns the number of rows. More...
 
bool __eq__ (ConstFMatrixExpression e)
 Returns the result of the comparison operation self == e. More...
 
bool __ne__ (ConstFMatrixExpression e)
 Returns the result of the comparison operation self != e. More...
 
str __str__ ()
 Returns a string representation of the ConstFMatrixExpression instance. More...
 
ConstFMatrixExpression __pos__ ()
 Returns self. More...
 
ConstFMatrixExpression __neg__ ()
 Returns the result of the operation self * -1. More...
 
ConstFMatrixExpression __add__ (ConstFMatrixExpression e)
 Returns the result of the addition operation self + e. More...
 
ConstFMatrixExpression __sub__ (ConstFMatrixExpression e)
 Returns the result of the subtraction operation self - e. More...
 
ConstFMatrixExpression __mul__ (float t)
 Returns the result of the multiplication operation self * t. More...
 
ConstFMatrixExpression __mul__ (ConstFMatrixExpression e)
 Returns the result of the multiplication operation self * e. More...
 
ConstFVectorExpression __mul__ (ConstFVectorExpression e)
 Returns the result of the multiplication operation self * e. More...
 
ConstFMatrixExpression __div__ (float t)
 Returns the result of the division operation self // t. More...
 
ConstFMatrixExpression __truediv__ (float t)
 Returns the result of the true division operation self / t. More...
 
ConstFMatrixExpression __rmul__ (float t)
 Returns the result of the multiplication operation t * self. More...
 

Additional Inherited Members

- Properties inherited from CDPL.Math.ConstFMatrixExpression
 objectID = property(getObjectID)
 
 size1 = property(getSize1)
 
 size2 = property(getSize2)
 

Detailed Description

Represents the outcome of mathematical expressions/operations that result in a matrix.

Member Function Documentation

◆ swap()

None CDPL.Math.FMatrixExpression.swap ( FMatrixExpression  e)

Swaps the contents of this matrix expression with those of e.

Parameters
eThe matrix expression to swap with.

◆ assign() [1/6]

FMatrixExpression CDPL.Math.FMatrixExpression.assign ( FMatrixExpression  e)

Assigns the contents of the matrix expression e to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ assign() [2/6]

FMatrixExpression CDPL.Math.FMatrixExpression.assign ( ConstFMatrixExpression  e)

Assigns the contents of the matrix expression e to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ assign() [3/6]

FMatrixExpression CDPL.Math.FMatrixExpression.assign ( ConstDMatrixExpression  e)

Assigns the contents of the matrix expression e to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ assign() [4/6]

FMatrixExpression CDPL.Math.FMatrixExpression.assign ( ConstLMatrixExpression  e)

Assigns the contents of the matrix expression e to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ assign() [5/6]

FMatrixExpression CDPL.Math.FMatrixExpression.assign ( ConstULMatrixExpression  e)

Assigns the contents of the matrix expression e to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ assign() [6/6]

None CDPL.Math.FMatrixExpression.assign ( object  a)

Assigns the contents of the 2D numpy.ndarray object a to this matrix expression.

Parameters
aThe numpy.ndarray object.
See also
[NUMPY]

◆ setElement()

None CDPL.Math.FMatrixExpression.setElement ( int  i,
int  j,
float  v 
)

Sets the value of the element (i, j) to v.

Parameters
iThe zero-based row index.
jThe zero-based column index.
Exceptions
Base.IndexErrorif any of the indices is out of range.

◆ __setitem__()

None CDPL.Math.FMatrixExpression.__setitem__ ( tuple  ij,
float  v 
)

Sets the value of the element (i, j) to v.

Parameters
iThe zero-based row index.
jThe zero-based column index.
vThe new value of the element.
Exceptions
Base.IndexErrorif any of the indices is out of range.

◆ __iadd__() [1/2]

FMatrixExpression CDPL.Math.FMatrixExpression.__iadd__ ( FMatrixExpression  e)

Adds the matrix expression e element-wise to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ __iadd__() [2/2]

FMatrixExpression CDPL.Math.FMatrixExpression.__iadd__ ( ConstFMatrixExpression  e)

Adds the matrix expression e element-wise to this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ __isub__() [1/2]

FMatrixExpression CDPL.Math.FMatrixExpression.__isub__ ( FMatrixExpression  e)

Subtracts the matrix expression e element-wise from this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ __isub__() [2/2]

FMatrixExpression CDPL.Math.FMatrixExpression.__isub__ ( ConstFMatrixExpression  e)

Subtracts the matrix expression e element-wise from this expression.

Parameters
eThe source matrix expression.
Returns
self.

◆ __imul__()

FMatrixExpression CDPL.Math.FMatrixExpression.__imul__ ( float  t)

Multiplies every element by the scalar t.

Parameters
tThe scalar multiplier.
Returns
self.

◆ __idiv__()

FMatrixExpression CDPL.Math.FMatrixExpression.__idiv__ ( float  t)

Divides every element by the scalar t.

Parameters
tThe scalar divisor.
Returns
self.

◆ __itruediv__()

FMatrixExpression CDPL.Math.FMatrixExpression.__itruediv__ ( float  t)

Divides every element by the scalar t.

Parameters
tThe scalar divisor.
Returns
self.