mrtr_utils.H File Reference

A couple utility methods for the Moertel package. More...

#include <ctime>
#include <iostream>
#include "Teuchos_RefCountPtr.hpp"
#include <Epetra_Comm.h>
#include <Epetra_SerialComm.h>
#include "Epetra_SerialDenseMatrix.h"
#include "Epetra_SerialDenseSolver.h"
#include "Epetra_CrsMatrix.h"
#include "Epetra_Vector.h"
#include "Epetra_Export.h"
#include "ml_common.h"
#include "ml_include.h"
#include "ml_epetra_utils.h"
#include "ml_epetra.h"
#include "ml_epetra_operator.h"
#include "mrtr_segment.H"
#include "mrtr_functions.H"
#include "mrtr_node.H"
#include "mrtr_point.H"

Include dependency graph for mrtr_utils.H:

This graph shows which files directly or indirectly include this file:


namespace  MOERTEL


MOERTEL::FunctionMOERTEL::AllocateFunction (MOERTEL::Function::FunctionType type, int out)
 Allocate a function of the correct type.
MOERTEL::SegmentMOERTEL::AllocateSegment (int type, int out)
 Allocate a Segment of the correct type.
bool MOERTEL::cross (double *out, const double *g1, const double *g2)
 Cross product.
double MOERTEL::dot (const double *g1, const double *g2, const int dim)
 Dot product.
double MOERTEL::length (const double *g, const int dim)
 Length of a vector.
bool MOERTEL::solve22 (const double A[][2], double *x, const double *b)
 Solve dense 2x2 system of equations.
bool MOERTEL::solve33 (const double A[][3], double *x, const double *b)
 Solve dense 3x3 system of equations.
int MOERTEL::digit_ten (int i)
 Return the '10' digit from an integer number.
void MOERTEL::sort (double *dlist, int N, int *list2)
 Sort dlist of length N in ascending, sort list2 according to dlist.
template<typename kind>
void MOERTEL::swap (kind &a, kind &b)
 Template to swap 2 <kind> instances.
int MOERTEL::MatrixMatrixAdd (const Epetra_CrsMatrix &A, bool transposeA, double scalarA, Epetra_CrsMatrix &B, double scalarB)
 Add matrices A+B.
Epetra_CrsMatrix * MOERTEL::MatMatMult (const Epetra_CrsMatrix &A, bool transA, const Epetra_CrsMatrix &B, bool transB, int outlevel)
 Multiply matrices A*B.
Epetra_CrsMatrix * MOERTEL::PaddedMatrix (const Epetra_Map rowmap, double val, const int numentriesperrow)
 Allocate and return a matrix padded with val on the diagonal. FillComplete() is NOT called on exit.
Epetra_CrsMatrix * MOERTEL::StripZeros (Epetra_CrsMatrix &A, double eps)
 Strip out values from a matrix below a certain tolerance.
bool MOERTEL::SplitMatrix2x2 (RefCountPtr< Epetra_CrsMatrix > A, RefCountPtr< Epetra_Map > &A11rowmap, RefCountPtr< Epetra_Map > &A22rowmap, RefCountPtr< Epetra_CrsMatrix > &A11, RefCountPtr< Epetra_CrsMatrix > &A12, RefCountPtr< Epetra_CrsMatrix > &A21, RefCountPtr< Epetra_CrsMatrix > &A22)
 split a matrix into a 2x2 block system where the rowmap of one of the blocks is given
Epetra_Map * MOERTEL::SplitMap (const Epetra_Map &Amap, const Epetra_Map &Agiven)
 split a rowmap of matrix A
bool MOERTEL::SplitVector (const Epetra_Vector &x, const Epetra_Map &x1map, Epetra_Vector *&x1, const Epetra_Map &x2map, Epetra_Vector *&x2)
 split a vector into 2 non-overlapping pieces
bool MOERTEL::MergeVector (const Epetra_Vector &x1, const Epetra_Vector &x2, Epetra_Vector &xresult)
 merge results from 2 vectors into one (assumes matching submaps)
bool MOERTEL::Print_Matrix (string name, Epetra_CrsMatrix &A, int ibase)
 Print matrix to file.
bool MOERTEL::Print_Graph (string name, Epetra_CrsGraph &A, int ibase)
 Print graph to file.
bool MOERTEL::Print_Vector (string name, Epetra_Vector &v, int ibase)
 Print vector to file.

Detailed Description

A couple utility methods for the Moertel package.

Last update do Doxygen: 16-Dec-05

Generated on Wed May 12 21:58:36 2010 for Moertel by  doxygen 1.4.7