Real diagonal matrix. More...
#include <matrix.h>
Public Member Functions | |
diagMatrix (int N=0, double d=0.) | |
int | nRows () const |
int | nCols () const |
bool | isScalar (double absTol=1e-14, double relTol=1e-14) const |
Check if all entries are identical within threshold. | |
diagMatrix & | operator*= (double s) |
diagMatrix | operator() (int iStart, int iStop) const |
get submatrix of elements (iStart <= i < iStop) | |
diagMatrix | operator() (int iStart, int iStep, int iStop) const |
get submatrix of elements (iStart <= i < iStop) with arbitrary increments | |
void | set (int iStart, int iStop, const diagMatrix &m) |
set submatrix to m | |
void | set (int iStart, int iStep, int iStop, const diagMatrix &m) |
set submatrix to m at arbitrary increments | |
void | scan (FILE *fp) |
read (ascii) from stream | |
void | print (FILE *fp, const char *fmt="%lg\t") const |
print (ascii) to stream | |
void | send (int dest, int tag=0) const |
send to another process | |
void | recv (int src, int tag=0) |
receive from another process | |
void | bcast (int root=0) |
synchronize across processes (using value on specified root process) | |
void | allReduce (MPIUtil::ReduceOp op, bool safeMode=false) |
apply all-to-all reduction (see MPIUtil::allReduce) | |
Additional Inherited Members | |
Public Attributes inherited from std::vector< T > | |
T | elements |
STL member. | |
Real diagonal matrix.