common.h File Reference

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <math.h>
#include <errno.h>
#include <cstdarg>
#include <algorithm>
#include <vector>
#include <set>

Go to the source code of this file.

Classes

struct  Point1D
struct  Point2D
struct  Point3D
struct  Vector3D

Defines

#define H3D_ERR_NOT_IMPLEMENTED   "Not yet implemened."
#define H3D_ERR_UNKNOWN_MODE   "Unknown mode (mode = %d)."
#define H3D_ERR_FACE_INDEX_OUT_OF_RANGE   "Face index out of range."
#define H3D_ERR_EDGE_INDEX_OUT_OF_RANGE   "Edge index out of range."
#define H3D_ERR_TETRA_NOT_COMPILED   "hermes3d was not built with tetra elements."
#define H3D_ERR_HEX_NOT_COMPILED   "hermes3d was not built with hex elements."
#define H3D_ERR_PRISM_NOT_COMPILED   "hermes3d was not built with prism elements."
#define H3D_ERR_UNKNOWN_REFINEMENT_TYPE   "Unknown refinement type (refinement = %d)."
#define CONJ(a)   (a)
#define REAL(a)   (a)
#define IMAG(a)   (0)
#define ABS(a)   (fabs(a))
#define SCALAR_FMT   "%lf"
#define SCALAR(a)   (a)
#define H3D_MAX_ELEMENT_ORDER   10
#define H3D_DIRICHLET_DOF   -1
#define countof(a)   (sizeof(a)/sizeof(a[0]))
#define H3D_EC_TIME   'T'
 An event code: time measurements.
#define H3D_REPORT_TIME
#define report_time(...)

Typedefs

typedef double scalar
typedef double double2 [2]
typedef double double3 [3]
typedef double double4 [4]
typedef double double2x2 [2][2]
typedef double double3x3 [3][3]
typedef int int2 [2]
typedef scalar scalar3 [3]
typedef unsigned long long int uint64

Enumerations

enum  EMode1D { MODE_LINE = 0 }
enum  EMode2D { MODE_TRIANGLE = 0, MODE_QUAD = 1 }
enum  EMode3D { MODE_TETRAHEDRON = 0, MODE_HEXAHEDRON = 1, MODE_PRISM = 2 }
enum  ESpaceType { H1 = 1, Hcurl = 2, Hdiv = 3, L2 = 4 }

Functions

int dscal_ (int *, double *, double *, int *)
int daxpy_ (int *, double *, double *, int *, double *, int *)
int dcopy_ (int *, double *, int *, double *, int *)
void blas_scal (int n, double alpha, double *x, int incx)
 x <- alpha * x
void blas_axpy (int n, double alpha, double *x, int incx, double *y, int incy)
 y <- alpha * x + y
void blas_copy (int n, double *x, int incx, double *y, int incy)
 y <- x
double dot_product (const Point3D &a, const Point3D &b)
Point3D cross_product (Point3D a, Point3D b)
Point3D lin_comb (Point3D a, double coef_a, Point3D b, double coef_b)
double norm (const Point3D &pt)
Point3D normalize (const Point3D &pt)
int sqr (int x)
double sqr (double x)

Variables

const int ANY = -1234

Define Documentation

#define ABS (  )     (fabs(a))
#define CONJ (  )     (a)
#define countof (  )     (sizeof(a)/sizeof(a[0]))
#define H3D_DIRICHLET_DOF   -1
#define H3D_EC_TIME   'T'

An event code: time measurements.

For internal use only.

#define H3D_ERR_EDGE_INDEX_OUT_OF_RANGE   "Edge index out of range."
#define H3D_ERR_FACE_INDEX_OUT_OF_RANGE   "Face index out of range."
#define H3D_ERR_HEX_NOT_COMPILED   "hermes3d was not built with hex elements."
#define H3D_ERR_NOT_IMPLEMENTED   "Not yet implemened."
#define H3D_ERR_PRISM_NOT_COMPILED   "hermes3d was not built with prism elements."
#define H3D_ERR_TETRA_NOT_COMPILED   "hermes3d was not built with tetra elements."
#define H3D_ERR_UNKNOWN_MODE   "Unknown mode (mode = %d)."
#define H3D_ERR_UNKNOWN_REFINEMENT_TYPE   "Unknown refinement type (refinement = %d)."
#define H3D_MAX_ELEMENT_ORDER   10
#define H3D_REPORT_TIME
#define IMAG (  )     (0)
#define REAL (  )     (a)
#define report_time ( ...   ) 
#define SCALAR (  )     (a)
#define SCALAR_FMT   "%lf"

Typedef Documentation

typedef double double2[2]
typedef double double2x2[2][2]
typedef double double3[3]
typedef double double3x3[3][3]
typedef double double4[4]
typedef int int2[2]
typedef double scalar
typedef scalar scalar3[3]
typedef unsigned long long int uint64

Enumeration Type Documentation

enum EMode1D
Enumerator:
MODE_LINE 
enum EMode2D
Enumerator:
MODE_TRIANGLE 
MODE_QUAD 
enum EMode3D
Enumerator:
MODE_TETRAHEDRON 
MODE_HEXAHEDRON 
MODE_PRISM 
enum ESpaceType
Enumerator:
H1 
Hcurl 
Hdiv 
L2 

Function Documentation

void blas_axpy ( int  n,
double  alpha,
double *  x,
int  incx,
double *  y,
int  incy 
) [inline]

y <- alpha * x + y

void blas_copy ( int  n,
double *  x,
int  incx,
double *  y,
int  incy 
) [inline]

y <- x

void blas_scal ( int  n,
double  alpha,
double *  x,
int  incx 
) [inline]

x <- alpha * x

Point3D cross_product ( Point3D  a,
Point3D  b 
) [inline]
int daxpy_ ( int *  ,
double *  ,
double *  ,
int *  ,
double *  ,
int *   
)
int dcopy_ ( int *  ,
double *  ,
int *  ,
double *  ,
int *   
)
double dot_product ( const Point3D a,
const Point3D b 
) [inline]
int dscal_ ( int *  ,
double *  ,
double *  ,
int *   
)
Point3D lin_comb ( Point3D  a,
double  coef_a,
Point3D  b,
double  coef_b 
) [inline]
double norm ( const Point3D pt  )  [inline]
Point3D normalize ( const Point3D pt  )  [inline]
double sqr ( double  x  )  [inline]
int sqr ( int  x  )  [inline]

Variable Documentation

const int ANY = -1234
Generated on Fri Sep 3 09:22:20 2010 for Hermes3D Library: Real Version by  doxygen 1.6.3