NumeRe v1.1.4
NumeRe: Framework für Numerische Rechnungen
matfuncs.hpp File Reference
#include <Eigen/Dense>
#include <Eigen/Eigenvalues>
#include <random>
#include <map>
#include "matdatastructures.hpp"
#include "../ui/error.hpp"
#include "../../kernel.hpp"
#include "functionimplementation.hpp"
#include "statslogic.hpp"
Include dependency graph for matfuncs.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define EIGENVALUES   0
 
#define EIGENVECTORS   1
 
#define DIAGONALIZE   2
 

Functions

std::mt19937 & getRandGenInstance ()
 Returns a reference to the central random number generator instance, which is globally accessible by all random number functions. More...
 
static std::string printMatrixDim (const Matrix &mat)
 Simple helper for printing the matrix dimensions to a string. More...
 
static Matrix createFilledMatrix (size_t n, size_t m, const mu::value_type &val)
 This static function returns a matrix filled with the passed value of the defined size. More...
 
static Matrix createZeroesMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function returns a matrix filled with zeros of the defined size. More...
 
static Matrix createOnesMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function returns a matrix filled with ones of the defined size. More...
 
static Matrix identityMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function returns an identity matrix of the defined size. More...
 
static Matrix calcTrace (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function calculates the trace of the passed matrix. More...
 
static mu::value_type calcDeterminant (const Matrix &_mMatrix, std::vector< int > vRemovedLines)
 This static function calculates the determinant of the passed matrix using the LaPlace algorithm. More...
 
static Matrix getDeterminant (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function calculates the determinant of the passed matrix. More...
 
static Matrix calcCrossProduct (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function calulates the n-dimensional cross product ("curl"). More...
 
 __attribute__ ((force_align_arg_pointer)) static Matrix calcEigenVectsAndValues(const Matrix &_mMatrix
 This static function does the whole eigenvalues, eigenvectors and diagonalizing stuff. More...
 
Eigen::MatrixXcd mMatrix (_mMatrix.rows(), _mMatrix.rows())
 
 for (unsigned int i=0;i< _mMatrix.rows();i++)
 
Eigen::ComplexEigenSolver< Eigen::MatrixXcd > eSolver (mMatrix)
 
 if (nReturnType==EIGENVALUES)
 
static Matrix calcEigenVects (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Calculates the eigenvectors of the passed matrix. More...
 
static Matrix calcEigenValues (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Calculates the eigenvalues of the passed matrix. More...
 
static Matrix diagonalize (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Diagonalizes the passed matrix using its eigenvalues. More...
 
static Matrix createShuffledMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function creates a shuffled vector of nShuffle elements created from a 1:nBase vector. More...
 
static Matrix invertMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Calculates the inverse matrix and checks in advance, whether the matrix is invertible. More...
 
static Matrix transposeMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function transposes a matrix. More...
 
static Matrix logToIndex (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function converts logical vectors into matrix indices. More...
 
static mu::value_type calculateStats (const Matrix &mat, StatsLogic logic, int rowStart, size_t rowCount, int colStart, size_t colCount)
 Driver code to calculate some statistics from a matrix while being able to use moving windows. The calculation is switched to parallel mode, once the moving window is large enough. More...
 
static Matrix matrixMax (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the max() function on the matrix elements. More...
 
static Matrix matrixMovMax (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the max() function. More...
 
static Matrix indexToLog (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function converts matrix indices into logical vectors. More...
 
static Matrix matrixSize (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function returns the size of the passed matrix. More...
 
static Matrix matrixAnd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the and() function on the matrix elements. More...
 
static Matrix matrixOr (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the or() function on the matrix elements. More...
 
static Matrix matrixXor (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the xor() function on the matrix elements. More...
 
static Matrix matrixSum (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the sum() function on the matrix elements. More...
 
static Matrix matrixMovSum (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the sum() function. More...
 
static Matrix matrixNum (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the num() function on the matrix elements. More...
 
static Matrix matrixMovNum (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the num() function. More...
 
static Matrix matrixAvg (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the avg() function on the matrix elements. More...
 
static Matrix matrixMovAvg (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the avg() function. More...
 
static Matrix matrixStd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the std() function on the matrix elements. More...
 
static Matrix matrixMovStd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the std() function. More...
 
static Matrix matrixPrd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the prd() function on the matrix elements. More...
 
static Matrix matrixMovPrd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the prd() function. More...
 
static Matrix matrixCnt (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the cnt() function on the matrix elements. More...
 
static Matrix matrixCutoff (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies a threshold to the complete matrix as specified by the arguments. More...
 
static Matrix matrixNorm (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the norm() function on the matrix elements. More...
 
static Matrix matrixMovNorm (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the norm() function. More...
 
static Matrix matrixMin (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the min() function on the matrix elements. More...
 
static Matrix matrixMovMin (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the min() function. More...
 
static Matrix matrixCmp (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the cmp() function on the matrix elements. More...
 
static Matrix matrixMinPos (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the minpos() function on the matrix elements. More...
 
static Matrix matrixMaxPos (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the maxpos() function on the matrix elements. More...
 
static Matrix matrixMed (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the med() function on the matrix elements. More...
 
static Matrix matrixMovMed (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Moving window version of the med() function. More...
 
static Matrix matrixPct (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function applies the pct() function on the matrix elements. More...
 
static Matrix matrixResize (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function changes the size of the passed matrix to fit the new size. More...
 
static Matrix correlation (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the cross- and auto-correlation matrix calculation from the passed two matrices. More...
 
static Matrix covariance (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the covariance calculation of the passed two matrices. More...
 
static Matrix normalize (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the normalize function, which will normalize the (absolute) data range of the passed matrix into the range [0,1]. More...
 
static Matrix matrixReshape (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function changes the number of rows and columns to fit the new shape. More...
 
static Matrix matrixRepMat (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function repeats the passed matrix n and m times. More...
 
static bool is_nan (const mu::value_type &value)
 Static helper function for std::list::remove_if() called in getUniqueList(). More...
 
static bool isSmallerRealOnly (const mu::value_type &value1, const mu::value_type &value2)
 Static helper function for std::sort() called in getUniqueList(). Determines a real-only order. More...
 
static std::vector< mu::value_typegetUniqueList (std::list< mu::value_type > &_list)
 This is a static helper function for the implementation of the unique() function. More...
 
static Matrix matrixUnique (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the unique(MAT,nDim) function. More...
 
static Matrix matrixCumSum (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the cumsum(MAT,nDim) function. More...
 
static Matrix matrixCumPrd (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the cumprd(MAT,nDim) function. More...
 
static void solveLGSSymbolic (const Matrix &_mMatrix, const MatFuncErrorInfo &errorInfo)
 This static function solves the system of linear equations symbolically. More...
 
static Matrix solveLGS (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function will solve the system of linear equations passed as matrix using the Gauss elimination algorithm. More...
 
static Matrix diagonalMatrix (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function implements the "diag()" function. More...
 
static Matrix cartToCyl (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts cartesian to cylindrical coordinates. More...
 
static Matrix cartToPolar (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts cartesian to polar coordinates. More...
 
static Matrix cylToCart (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts cylindrical to cartesian coordinates. More...
 
static Matrix cylToPolar (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts cylindrical to polar coordinates. More...
 
static Matrix polarToCart (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts polar to cartesian coordinates. More...
 
static Matrix polarToCyl (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Converts polar to cylindrical coordinates. More...
 
static size_t findNearestLowerGridAxisValue (const Matrix &gaxes, size_t axis, double axisval)
 This static function finds the nearest lower grid axis value. More...
 
static Matrix coordsToGrid (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function converts floating point coordinates to grid coordinates by using the grid axes as reference values. More...
 
static mu::value_type readMat (const Matrix &mat, int row, int col)
 Static helper function for bilinearInterpolation(). More...
 
static mu::value_type bilinearInterpolation (const Matrix &mat, double row, double col)
 Performs the bilinear interpolation of the matrix value at the selected coordinates. More...
 
static Matrix interpolate (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static function wraps the bilinear interpolation algorithm for interpolating the values of the first matrix in the coordinates of the second matrix. More...
 
static Matrix hcat (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static functions concatenates two matrices horizontally. This is, the number of rows stays the same and the columns are appended to the ones of the other matrix. More...
 
static Matrix vcat (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 This static functions concatenates two matrices vertically. This is, the number of columns stays the same and the rows are appended to the ones of the other matrix. More...
 
static Matrix selection (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Extracts a selection from a matrix iterating through two matrices simultaneously. More...
 
static Matrix assemble (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Assembles a matrix from coordinates and values (a datagrid replacement without interpolation). More...
 
static Matrix polyLength (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Calculates the length of an open polygon. If the circumference of a closed polygon shall be calculated, then append the first vertex at the end of the polygon. More...
 
static mu::value_type applyKernel (const Matrix &kernel, const Matrix &inMatrix, const VectorIndex &rows, const VectorIndex &cols, const size_t startRow, const size_t startCol)
 This static helper function applies the kernel to the subset of a matrix using the provided indices. More...
 
static Matrix matrixFilter (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Function that allows the user to apply a customer filter kernel to a matrix while applying different boundary conditions. More...
 
static Matrix invalidMatrixFunction (const MatFuncData &funcData, const MatFuncErrorInfo &errorInfo)
 Static invalid matrix function, which will always throw an error. More...
 
static std::map< std::string, MatFuncDefgetMatrixFunctions ()
 Returns a map containing all declared and "standard" matrix functions. More...
 

Variables

int nReturnType
 
int const MatFuncErrorInfoerrorInfo
 
if(!_mMatrix.isSquare()) throw SyntaxError(SyntaxError if(_mMatrix.containsInvalidValues()) throw SyntaxError(SyntaxError Matrix _mEigenVals
 
Matrix _mEigenVects
 

Macro Definition Documentation

◆ DIAGONALIZE

#define DIAGONALIZE   2

Definition at line 24 of file matfuncs.hpp.

◆ EIGENVALUES

#define EIGENVALUES   0

Definition at line 22 of file matfuncs.hpp.

◆ EIGENVECTORS

#define EIGENVECTORS   1

Definition at line 23 of file matfuncs.hpp.

Function Documentation

◆ __attribute__()

__attribute__ ( (force_align_arg_pointer)  ) const &

This static function does the whole eigenvalues, eigenvectors and diagonalizing stuff.

Parameters
_mMatrixconst Matrix&
nReturnTypeint
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

If the results are complex then the real and imaginary parts of the result are returned as separate results:

  • for eigenvalues it's two columns of the returned matrix
  • for eigenvectors or the diagonal matrix it's a matrix with 2N columns, where the imaginary part may be found in the columns N+1 - 2N

__attribute__((force_align_arg_pointer)) fixes TDM-GCC Bug for wrong stack alignment.

References MatFuncErrorInfo::command, Matrix::containsInvalidValues(), errorInfo, Matrix::isEmpty(), Matrix::isSquare(), SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, SyntaxError::MATRIX_CONTAINS_INVALID_VALUES, MatFuncErrorInfo::position, printMatrixDim(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Here is the call graph for this function:

◆ applyKernel()

static mu::value_type applyKernel ( const Matrix kernel,
const Matrix inMatrix,
const VectorIndex rows,
const VectorIndex cols,
const size_t  startRow,
const size_t  startCol 
)
static

This static helper function applies the kernel to the subset of a matrix using the provided indices.

Parameters
kernelconst Matrix&
inMatrixconst Matrix&
rowsconst VectorIndex&
colsconst VectorIndex&
Returns
mu::value_type

Definition at line 3326 of file matfuncs.hpp.

References Matrix::cols(), and Matrix::rows().

Referenced by matrixFilter().

Here is the call graph for this function:

◆ assemble()

static Matrix assemble ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Assembles a matrix from coordinates and values (a datagrid replacement without interpolation).

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3216 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, intCast(), Matrix::isEmpty(), Matrix::isScalar(), MatFuncData::mat1, MatFuncData::mat2, MatFuncData::mat3, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_MAX, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ bilinearInterpolation()

static mu::value_type bilinearInterpolation ( const Matrix mat,
double  row,
double  col 
)
static

Performs the bilinear interpolation of the matrix value at the selected coordinates.

Parameters
matconst Matrix&
rowdouble
coldouble
Returns
double

Definition at line 3021 of file matfuncs.hpp.

References intCast(), mu::isnan(), and readMat().

Referenced by interpolate().

Here is the call graph for this function:

◆ calcCrossProduct()

static Matrix calcCrossProduct ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function calulates the n-dimensional cross product ("curl").

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 279 of file matfuncs.hpp.

References calcDeterminant(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ calcDeterminant()

static mu::value_type calcDeterminant ( const Matrix _mMatrix,
std::vector< int >  vRemovedLines 
)
static

This static function calculates the determinant of the passed matrix using the LaPlace algorithm.

Parameters
_mMatrixconst Matrix&
vRemovedLinesstd::vector<int>
Returns
mu::value_type

Definition at line 182 of file matfuncs.hpp.

References calcDeterminant(), and Matrix::rows().

Referenced by calcCrossProduct(), calcDeterminant(), and getDeterminant().

Here is the call graph for this function:

◆ calcEigenValues()

static Matrix calcEigenValues ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Calculates the eigenvalues of the passed matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 457 of file matfuncs.hpp.

References EIGENVALUES, errorInfo, and MatFuncData::mat1.

Referenced by getMatrixFunctions().

◆ calcEigenVects()

static Matrix calcEigenVects ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Calculates the eigenvectors of the passed matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 442 of file matfuncs.hpp.

References EIGENVECTORS, errorInfo, and MatFuncData::mat1.

Referenced by getMatrixFunctions().

◆ calcTrace()

static Matrix calcTrace ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function calculates the trace of the passed matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 152 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), Matrix::isSquare(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ calculateStats()

static mu::value_type calculateStats ( const Matrix mat,
StatsLogic  logic,
int  rowStart,
size_t  rowCount,
int  colStart,
size_t  colCount 
)
static

Driver code to calculate some statistics from a matrix while being able to use moving windows. The calculation is switched to parallel mode, once the moving window is large enough.

Parameters
matconst Matrix&
logicStatsLogic
rowStartint
rowCountsize_t
colStartint
colCountsize_t
Returns
mu::value_type

Definition at line 778 of file matfuncs.hpp.

References Matrix::cols(), and Matrix::rows().

Referenced by assemble(), matrixCutoff(), matrixMax(), matrixMin(), matrixMovAvg(), matrixMovMax(), matrixMovMin(), matrixMovNorm(), matrixMovNum(), matrixMovPrd(), matrixMovStd(), matrixMovSum(), matrixNorm(), matrixNum(), matrixPrd(), matrixStd(), and matrixSum().

Here is the call graph for this function:

◆ cartToCyl()

static Matrix cartToCyl ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts cartesian to cylindrical coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2721 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, intPower(), Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, parser_phi(), MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by cartToPolar(), and getMatrixFunctions().

Here is the call graph for this function:

◆ cartToPolar()

static Matrix cartToPolar ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts cartesian to polar coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2752 of file matfuncs.hpp.

References cartToCyl(), Matrix::cols(), MatFuncErrorInfo::command, errorInfo, intPower(), Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, parser_phi(), parser_theta(), MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ coordsToGrid()

static Matrix coordsToGrid ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function converts floating point coordinates to grid coordinates by using the grid axes as reference values.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2954 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, findNearestLowerGridAxisValue(), Matrix::isEmpty(), MatFuncData::mat1, MatFuncData::mat2, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), mu::real(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ correlation()

static Matrix correlation ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the cross- and auto-correlation matrix calculation from the passed two matrices.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

If their sizes are not fitting, they are resized to fit.

Definition at line 1877 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, MatFuncData::mat2, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, max, min, MatFuncErrorInfo::position, printMatrixDim(), Matrix::resize(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ covariance()

static Matrix covariance ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the covariance calculation of the passed two matrices.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1935 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, MatFuncData::mat2, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixAvg(), MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ createFilledMatrix()

◆ createOnesMatrix()

static Matrix createOnesMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function returns a matrix filled with ones of the defined size.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 103 of file matfuncs.hpp.

References MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ createShuffledMatrix()

static Matrix createShuffledMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function creates a shuffled vector of nShuffle elements created from a 1:nBase vector.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 488 of file matfuncs.hpp.

References MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, getRandGenInstance(), SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, MatFuncErrorInfo::position, Matrix::resize(), and mu::rint().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ createZeroesMatrix()

static Matrix createZeroesMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function returns a matrix filled with zeros of the defined size.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 79 of file matfuncs.hpp.

References MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions(), and polyLength().

Here is the call graph for this function:

◆ cylToCart()

static Matrix cylToCart ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts cylindrical to cartesian coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2789 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions(), and polarToCart().

Here is the call graph for this function:

◆ cylToPolar()

static Matrix cylToPolar ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts cylindrical to polar coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2820 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, intPower(), Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, parser_theta(), MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ diagonalize()

static Matrix diagonalize ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Diagonalizes the passed matrix using its eigenvalues.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 472 of file matfuncs.hpp.

References DIAGONALIZE, errorInfo, and MatFuncData::mat1.

Referenced by getMatrixFunctions().

◆ diagonalMatrix()

static Matrix diagonalMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the "diag()" function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2694 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixReshape(), MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ eSolver()

Eigen::ComplexEigenSolver< Eigen::MatrixXcd > eSolver ( mMatrix  )

Referenced by if().

◆ findNearestLowerGridAxisValue()

static size_t findNearestLowerGridAxisValue ( const Matrix gaxes,
size_t  axis,
double  axisval 
)
static

This static function finds the nearest lower grid axis value.

Parameters
gaxesconst Matrix&
axissize_t
axisvaldouble
Returns
size_t

Definition at line 2925 of file matfuncs.hpp.

References Matrix::cols(), mu::real(), and Matrix::rows().

Referenced by coordsToGrid().

Here is the call graph for this function:

◆ for()

for ( )

Definition at line 376 of file matfuncs.hpp.

References mMatrix(), and Matrix::rows().

Referenced by gen_bitlen(), init_block(), and unzReadCurrentFile().

Here is the call graph for this function:

◆ getDeterminant()

static Matrix getDeterminant ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function calculates the determinant of the passed matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 256 of file matfuncs.hpp.

References calcDeterminant(), MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), Matrix::isSquare(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions(), and invertMatrix().

Here is the call graph for this function:

◆ getMatrixFunctions()

◆ getRandGenInstance()

std::mt19937 & getRandGenInstance ( )

Returns a reference to the central random number generator instance, which is globally accessible by all random number functions.

Returns
std::mt19937&

Definition at line 91 of file tools.cpp.

References ThreadsafeRandGen::getGenerator(), and randGenerator.

Referenced by createShuffledMatrix(), parser_gRandom(), and parser_Random().

Here is the call graph for this function:

◆ getUniqueList()

static std::vector< mu::value_type > getUniqueList ( std::list< mu::value_type > &  _list)
static

This is a static helper function for the implementation of the unique() function.

Parameters
_liststd::list<mu::value_type>&
Returns
std::vector<mu::value_type>

Definition at line 2126 of file matfuncs.hpp.

References is_nan(), and isSmallerRealOnly().

Referenced by matrixUnique().

Here is the call graph for this function:

◆ hcat()

static Matrix hcat ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static functions concatenates two matrices horizontally. This is, the number of rows stays the same and the columns are appended to the ones of the other matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3109 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, Matrix::hcat(), MatFuncData::mat1, MatFuncData::mat2, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ identityMatrix()

static Matrix identityMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function returns an identity matrix of the defined size.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 127 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::nVal, and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions(), and invertMatrix().

◆ if()

Definition at line 390 of file matfuncs.hpp.

References _mEigenVals, eSolver(), and Matrix::rows().

Referenced by TZip::Add(), TZip::AddCentral(), calculateHist1dData(), TUnzip::Find(), listDirectory(), wxTreeListMainWindow::SelectItem(), wxTreeListMainWindow::SetDragItem(), wxTreeListMainWindow::SetItemBold(), and unzReadCurrentFile().

Here is the call graph for this function:

◆ indexToLog()

static Matrix indexToLog ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function converts matrix indices into logical vectors.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 893 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixMax(), MatFuncErrorInfo::position, mu::real(), and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ interpolate()

static Matrix interpolate ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function wraps the bilinear interpolation algorithm for interpolating the values of the first matrix in the coordinates of the second matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3066 of file matfuncs.hpp.

References bilinearInterpolation(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, MatFuncData::mat2, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, max, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ invalidMatrixFunction()

static Matrix invalidMatrixFunction ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Static invalid matrix function, which will always throw an error.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3425 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, SyntaxError::FUNCTION_ERROR, and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions().

◆ invertMatrix()

static Matrix invertMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Calculates the inverse matrix and checks in advance, whether the matrix is invertible.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 536 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, Matrix::containsInvalidValues(), errorInfo, getDeterminant(), identityMatrix(), Matrix::isEmpty(), Matrix::isSquare(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, SyntaxError::MATRIX_CONTAINS_INVALID_VALUES, SyntaxError::MATRIX_IS_NOT_INVERTIBLE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ is_nan()

static bool is_nan ( const mu::value_type value)
static

Static helper function for std::list::remove_if() called in getUniqueList().

Parameters
valueconst mu::value_type&
Returns
bool

Definition at line 2095 of file matfuncs.hpp.

References mu::isnan().

Referenced by getUniqueList().

Here is the call graph for this function:

◆ isSmallerRealOnly()

static bool isSmallerRealOnly ( const mu::value_type value1,
const mu::value_type value2 
)
static

Static helper function for std::sort() called in getUniqueList(). Determines a real-only order.

Parameters
value1const mu::value_type&
value2const mu::value_type&
Returns
bool

Definition at line 2111 of file matfuncs.hpp.

Referenced by getUniqueList().

◆ logToIndex()

static Matrix logToIndex ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function converts logical vectors into matrix indices.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 703 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixAnd()

static Matrix matrixAnd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the and() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1005 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixAvg()

static Matrix matrixAvg ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the avg() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1204 of file matfuncs.hpp.

References MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixNum(), matrixSum(), and MatFuncErrorInfo::position.

Referenced by covariance(), getMatrixFunctions(), and matrixStd().

Here is the call graph for this function:

◆ matrixCmp()

static Matrix matrixCmp ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the cmp() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1618 of file matfuncs.hpp.

References date::abs(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, MatFuncData::fVal, Matrix::isEmpty(), mu::isinf(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::nVal, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions(), matrixMaxPos(), and matrixMinPos().

Here is the call graph for this function:

◆ matrixCnt()

static Matrix matrixCnt ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the cnt() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1392 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixCumPrd()

static Matrix matrixCumPrd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the cumprd(MAT,nDim) function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2318 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, Matrix::data(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixReshape(), MatFuncData::nVal, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixCumSum()

static Matrix matrixCumSum ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the cumsum(MAT,nDim) function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2243 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, Matrix::data(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixReshape(), MatFuncData::nVal, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixCutoff()

static Matrix matrixCutoff ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies a threshold to the complete matrix as specified by the arguments.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1411 of file matfuncs.hpp.

References date::abs(), calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, SyntaxError::CUTOFF_MODE_INVALID, errorInfo, MatFuncData::fVal, mu::isnan(), MatFuncData::mat1, MatFuncData::nVal, StatsLogic::OPERATION_MAX, StatsLogic::OPERATION_MIN, MatFuncErrorInfo::position, mu::real(), and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixFilter()

static Matrix matrixFilter ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Function that allows the user to apply a customer filter kernel to a matrix while applying different boundary conditions.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3354 of file matfuncs.hpp.

References VectorIndex::append(), applyKernel(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_FILTER_SIZE, SyntaxError::INVALID_MODE, Matrix::isEmpty(), MatFuncData::mat1, MatFuncData::mat2, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::nVal, MatFuncErrorInfo::position, VectorIndex::prepend(), and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMax()

static Matrix matrixMax ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the max() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 839 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_MAX, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions(), indexToLog(), matrixMaxPos(), and normalize().

Here is the call graph for this function:

◆ matrixMaxPos()

static Matrix matrixMaxPos ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the maxpos() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1716 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixCmp(), matrixMax(), and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMed()

static Matrix matrixMed ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the med() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1734 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), Matrix::data(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, Memory::med(), MatFuncErrorInfo::position, Matrix::rows(), Memory::writeData(), and Memory::writeDataDirectUnsafe().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMin()

static Matrix matrixMin ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the min() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1564 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_MIN, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions(), matrixMinPos(), and normalize().

Here is the call graph for this function:

◆ matrixMinPos()

static Matrix matrixMinPos ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the minpos() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1698 of file matfuncs.hpp.

References MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixCmp(), matrixMin(), and MatFuncErrorInfo::position.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovAvg()

static Matrix matrixMovAvg ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the avg() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1225 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_ADD, StatsLogic::OPERATION_NUM, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovMax()

static Matrix matrixMovMax ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the max() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 858 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_MAX, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovMed()

static Matrix matrixMovMed ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the med() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1764 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, Memory::med(), MatFuncData::mVal, MatFuncData::nVal, MatFuncErrorInfo::position, Matrix::rows(), and Memory::writeData().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovMin()

static Matrix matrixMovMin ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the min() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1583 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_MIN, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovNorm()

static Matrix matrixMovNorm ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the norm() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1529 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_ADDSQ, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovNum()

static Matrix matrixMovNum ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the num() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1169 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_NUM, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovPrd()

static Matrix matrixMovPrd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the prd() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1357 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_MULT, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovStd()

static Matrix matrixMovStd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the std() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1292 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_ADD, StatsLogic::OPERATION_ADDSQSUB, StatsLogic::OPERATION_NUM, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixMovSum()

static Matrix matrixMovSum ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Moving window version of the sum() function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1115 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, SyntaxError::INVALID_STATS_WINDOW_SIZE, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::mVal, MatFuncData::nVal, StatsLogic::OPERATION_ADD, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixNorm()

static Matrix matrixNorm ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the norm() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1507 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_ADDSQ, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixNum()

static Matrix matrixNum ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the num() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1150 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_NUM, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions(), matrixAvg(), and matrixStd().

Here is the call graph for this function:

◆ matrixOr()

static Matrix matrixOr ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the or() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1032 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixPct()

static Matrix matrixPct ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the pct() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1816 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), Matrix::data(), errorInfo, MatFuncData::fVal, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, Memory::pct(), MatFuncErrorInfo::position, Matrix::rows(), Memory::writeData(), and Memory::writeDataDirectUnsafe().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixPrd()

static Matrix matrixPrd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the prd() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1338 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_MULT, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixRepMat()

static Matrix matrixRepMat ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function repeats the passed matrix n and m times.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2051 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, MatFuncData::fVal, MatFuncData::mat1, MatFuncData::nVal, MatFuncErrorInfo::position, Matrix::rows(), and SyntaxError::TOO_LARGE_CACHE.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixReshape()

static Matrix matrixReshape ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function changes the number of rows and columns to fit the new shape.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

The total number of elements before and afterwards must be identical.

Definition at line 2018 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, MatFuncData::fVal, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::nVal, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by diagonalMatrix(), getMatrixFunctions(), matrixCumPrd(), matrixCumSum(), and matrixUnique().

Here is the call graph for this function:

◆ matrixResize()

static Matrix matrixResize ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function changes the size of the passed matrix to fit the new size.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Missing elements are filled up with zeros.

Definition at line 1847 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, MatFuncData::fVal, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncData::nVal, MatFuncErrorInfo::position, Matrix::resize(), and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixSize()

static Matrix matrixSize ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function returns the size of the passed matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 979 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), mu::isnan(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixStd()

static Matrix matrixStd ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the std() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1268 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixAvg(), matrixNum(), StatsLogic::OPERATION_ADDSQSUB, MatFuncErrorInfo::position, mu::real(), and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixSum()

static Matrix matrixSum ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the sum() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1096 of file matfuncs.hpp.

References calculateStats(), Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, StatsLogic::OPERATION_ADD, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions(), and matrixAvg().

Here is the call graph for this function:

◆ matrixUnique()

static Matrix matrixUnique ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the unique(MAT,nDim) function.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2156 of file matfuncs.hpp.

References Matrix::assign(), Matrix::cols(), MatFuncErrorInfo::command, Matrix::data(), errorInfo, getUniqueList(), Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixReshape(), MatFuncData::nVal, MatFuncErrorInfo::position, Matrix::rows(), and Matrix::transpose().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ matrixXor()

static Matrix matrixXor ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function applies the xor() function on the matrix elements.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1059 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ mMatrix()

Eigen::MatrixXcd mMatrix ( _mMatrix.  rows(),
_mMatrix.  rows() 
)

Referenced by for().

◆ normalize()

static Matrix normalize ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function implements the normalize function, which will normalize the (absolute) data range of the passed matrix into the range [0,1].

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 1982 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, matrixMax(), matrixMin(), max, MatFuncErrorInfo::position, and Matrix::rows().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ polarToCart()

static Matrix polarToCart ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts polar to cartesian coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2856 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, cylToCart(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ polarToCyl()

static Matrix polarToCyl ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Converts polar to cylindrical coordinates.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2891 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), toString(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ polyLength()

static Matrix polyLength ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Calculates the length of an open polygon. If the circumference of a closed polygon shall be calculated, then append the first vertex at the end of the polygon.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3287 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createZeroesMatrix(), errorInfo, Matrix::isEmpty(), MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ printMatrixDim()

static std::string printMatrixDim ( const Matrix mat)
inlinestatic

Simple helper for printing the matrix dimensions to a string.

Parameters
matconst Matrix&
Returns
std::string

Definition at line 47 of file matfuncs.hpp.

References Matrix::printDims().

Referenced by __attribute__(), assemble(), calcCrossProduct(), calcTrace(), cartToCyl(), cartToPolar(), coordsToGrid(), correlation(), covariance(), cylToCart(), cylToPolar(), getDeterminant(), hcat(), interpolate(), invertMatrix(), matrixReshape(), polarToCart(), polarToCyl(), polyLength(), selection(), and vcat().

Here is the call graph for this function:

◆ readMat()

static mu::value_type readMat ( const Matrix mat,
int  row,
int  col 
)
static

Static helper function for bilinearInterpolation().

Parameters
matconst Matrix&
rowint
colint
Returns
mu::value_type

Definition at line 3002 of file matfuncs.hpp.

References Matrix::cols(), and Matrix::rows().

Referenced by bilinearInterpolation().

Here is the call graph for this function:

◆ selection()

static Matrix selection ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

Extracts a selection from a matrix iterating through two matrices simultaneously.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3151 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, intCast(), Matrix::isEmpty(), Matrix::isScalar(), MatFuncData::mat1, MatFuncData::mat2, MatFuncData::mat3, max, MatFuncErrorInfo::position, printMatrixDim(), Matrix::rows(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions(), NumeReWindow::HandleModifiedFile(), NumeReWindow::OnFileEventTimer(), NumeReEditor::OnMouseDblClk(), NumeReEditor::OnMouseDwell(), and RevisionDialog::OnRightClick().

Here is the call graph for this function:

◆ solveLGS()

static Matrix solveLGS ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function will solve the system of linear equations passed as matrix using the Gauss elimination algorithm.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 2529 of file matfuncs.hpp.

References _lang, Matrix::cols(), MatFuncErrorInfo::command, createFilledMatrix(), errorInfo, Language::get(), Matrix::isEmpty(), SyntaxError::LGS_HAS_NO_SOLUTION, MatFuncData::mat1, SyntaxError::MATRIX_CANNOT_HAVE_ZERO_SIZE, MatFuncErrorInfo::position, NumeReKernel::print(), Matrix::rows(), solveLGSSymbolic(), and toSystemCodePage().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ solveLGSSymbolic()

static void solveLGSSymbolic ( const Matrix _mMatrix,
const MatFuncErrorInfo errorInfo 
)
static

◆ transposeMatrix()

static Matrix transposeMatrix ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static function transposes a matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 686 of file matfuncs.hpp.

References MatFuncData::mat1, and Matrix::transpose().

Referenced by getMatrixFunctions().

Here is the call graph for this function:

◆ vcat()

static Matrix vcat ( const MatFuncData funcData,
const MatFuncErrorInfo errorInfo 
)
static

This static functions concatenates two matrices vertically. This is, the number of columns stays the same and the rows are appended to the ones of the other matrix.

Parameters
funcDataconst MatFuncData&
errorInfoconst MatFuncErrorInfo&
Returns
Matrix

Definition at line 3131 of file matfuncs.hpp.

References Matrix::cols(), MatFuncErrorInfo::command, errorInfo, MatFuncData::mat1, MatFuncData::mat2, MatFuncErrorInfo::position, printMatrixDim(), Matrix::vcat(), and SyntaxError::WRONG_MATRIX_DIMENSIONS_FOR_MATOP.

Referenced by getMatrixFunctions().

Here is the call graph for this function:

Variable Documentation

◆ _mEigenVals

if (!_mMatrix.isSquare()) throw SyntaxError(SyntaxError if (_mMatrix.containsInvalidValues()) throw SyntaxError(SyntaxError Matrix _mEigenVals

Definition at line 369 of file matfuncs.hpp.

Referenced by if().

◆ _mEigenVects

else return _mEigenVects

Definition at line 370 of file matfuncs.hpp.

◆ errorInfo

int const MatFuncErrorInfo& errorInfo
Initial value:
{
if (_mMatrix.isEmpty())
Common exception class for all exceptions thrown in NumeRe.
Definition: error.hpp:32
@ MATRIX_CANNOT_HAVE_ZERO_SIZE
Definition: error.hpp:155
int const MatFuncErrorInfo & errorInfo
Definition: matfuncs.hpp:358
const std::string & command

Definition at line 357 of file matfuncs.hpp.

Referenced by __attribute__(), assemble(), calcCrossProduct(), calcEigenValues(), calcEigenVects(), calcTrace(), cartToCyl(), cartToPolar(), coordsToGrid(), correlation(), covariance(), createOnesMatrix(), createShuffledMatrix(), createZeroesMatrix(), cylToCart(), cylToPolar(), diagonalize(), diagonalMatrix(), evalMatOp(), getDeterminant(), hcat(), identityMatrix(), indexToLog(), interpolate(), invalidMatrixFunction(), invertMatrix(), logToIndex(), matrixAnd(), matrixAvg(), matrixCmp(), matrixCnt(), matrixCumPrd(), matrixCumSum(), matrixCutoff(), matrixFilter(), matrixMax(), matrixMaxPos(), matrixMed(), matrixMin(), matrixMinPos(), matrixMovAvg(), matrixMovMax(), matrixMovMed(), matrixMovMin(), matrixMovNorm(), matrixMovNum(), matrixMovPrd(), matrixMovStd(), matrixMovSum(), matrixNorm(), matrixNum(), matrixOr(), matrixPct(), matrixPrd(), matrixRepMat(), matrixReshape(), matrixResize(), matrixSize(), matrixStd(), matrixSum(), matrixUnique(), matrixXor(), normalize(), polarToCart(), polarToCyl(), polyLength(), selection(), solveLGS(), solveLGSSymbolic(), and vcat().

◆ nReturnType

int nReturnType

Definition at line 357 of file matfuncs.hpp.