Galeri::FiniteElements::GalerkinVariational< T > Class Template Reference

Defines a pure Galerkin variational form of a scalar PDE. More...

#include <Galeri_GalerkinVariational.h>

Inheritance diagram for Galeri::FiniteElements::GalerkinVariational< T >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 GalerkinVariational (const int NumQuadratureNodes, double(*diff)(const double &, const double &, const double &), double(*source)(const double &, const double &, const double &), double(*force)(const double &, const double &, const double &), double(*bc)(const double &, const double &, const double &, const int &), int(*bc_type)(const int &))
 Constructor.
 ~GalerkinVariational ()
 Destructor.
double diff (const double x, const double y, const double z) const
 Evaluates the diffusion coefficient at point (x, y, z).
double source (const double x, const double y, const double z) const
 Evaluates the source term at point (x, y, z).
double force (const double x, const double y, const double z) const
 Evaluates the force term at point (x, y, z).
virtual int IntegrateOverElement (const AbstractVariational &Variational, const double *x, const double *y, const double *z, const double *data, double *ElementMatrix, double *ElementRHS) const
 Integrates the variational form and the right-hand side.
virtual int ElementNorm (const double *LocalSol, const double *x, const double *y, const double *z, double *Norm) const
 Computes the norm of the numerical solution over an element.
virtual int ElementNorm (int(*ExactSolution)(double, double, double, double *), const double *x, const double *y, const double *z, double *Norm) const
 Computes the norm of the exact solution over an element.
virtual int ElementNorm (const double *LocalSol, int(*ExactSolution)(double, double, double, double *), const double *x, const double *y, const double *z, double *Norm) const
 Computes the norm of the error over an element.
double LHS (const double Phi, const double Psi, const double PhiX, const double PsiX, const double PhiY, const double PsiY, const double PhiZ, const double PsiZ, const double x, const double y, const double z) const
 Evaluates the left-hand side at point (x, y, z).
double RHS (const double Psi, const double PsiX, const double PsiY, const double PsiZ, const double x, const double y, const double z) const
 Evaluates the right-hand side at point (x, y, z).
int BC (const int PatchID) const
 Returns the boundary condition type of the specified patch.
double BC (const double x, const double y, const double z, const int PatchID) const
 Returns the value of the boundary condition at point (x, y, z).

Private Attributes

double(* diff_ )(const double &x, const double &y, const double &z)
double(* source_ )(const double &x, const double &y, const double &z)
double(* force_ )(const double &x, const double &y, const double &z)
double(* bc_ )(const double &x, const double &y, const double &z, const int &Patch)
int(* bc_type_ )(const int &Patch)

Detailed Description

template<class T>
class Galeri::FiniteElements::GalerkinVariational< T >

Defines a pure Galerkin variational form of a scalar PDE.

This class defines a pure Galerkin variational form of a second order, symmetric scalar PDE, discretized using Lagrange finite elements. The class is templated with an AbstractQuadrature class, which will be used to specify the quadrature formula, and the values of test and basis functions at the quadrature node. The constructor requires function pointers, that specify the values of the coefficients.

Author:
Marzio Sala, SNL 9214.
Date:
Last updated on Apr-05.

Definition at line 61 of file Galeri_GalerkinVariational.h.


Constructor & Destructor Documentation

template<class T >
Galeri::FiniteElements::GalerkinVariational< T >::GalerkinVariational ( const int  NumQuadratureNodes,
double(*)(const double &, const double &, const double &)  diff,
double(*)(const double &, const double &, const double &)  source,
double(*)(const double &, const double &, const double &)  force,
double(*)(const double &, const double &, const double &, const int &)  bc,
int(*)(const int &)  bc_type 
) [inline]

Constructor.

Definition at line 66 of file Galeri_GalerkinVariational.h.

template<class T >
Galeri::FiniteElements::GalerkinVariational< T >::~GalerkinVariational (  )  [inline]

Destructor.

Definition at line 81 of file Galeri_GalerkinVariational.h.


Member Function Documentation

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::diff ( const double  x,
const double  y,
const double  z 
) const [inline]

Evaluates the diffusion coefficient at point (x, y, z).

Definition at line 84 of file Galeri_GalerkinVariational.h.

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::source ( const double  x,
const double  y,
const double  z 
) const [inline]

Evaluates the source term at point (x, y, z).

Definition at line 90 of file Galeri_GalerkinVariational.h.

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::force ( const double  x,
const double  y,
const double  z 
) const [inline]

Evaluates the force term at point (x, y, z).

Definition at line 96 of file Galeri_GalerkinVariational.h.

template<class T >
virtual int Galeri::FiniteElements::GalerkinVariational< T >::IntegrateOverElement ( const AbstractVariational Variational,
const double *  x,
const double *  y,
const double *  z,
const double *  data,
double *  ElementMatrix,
double *  ElementRHS 
) const [inline, virtual]

Integrates the variational form and the right-hand side.

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 102 of file Galeri_GalerkinVariational.h.

template<class T >
virtual int Galeri::FiniteElements::GalerkinVariational< T >::ElementNorm ( const double *  LocalSol,
const double *  x,
const double *  y,
const double *  z,
double *  Norm 
) const [inline, virtual]

Computes the norm of the numerical solution over an element.

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 144 of file Galeri_GalerkinVariational.h.

template<class T >
virtual int Galeri::FiniteElements::GalerkinVariational< T >::ElementNorm ( int(*)(double, double, double, double *)  ExactSolution,
const double *  x,
const double *  y,
const double *  z,
double *  Norm 
) const [inline, virtual]

Computes the norm of the exact solution over an element.

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 179 of file Galeri_GalerkinVariational.h.

template<class T >
virtual int Galeri::FiniteElements::GalerkinVariational< T >::ElementNorm ( const double *  LocalSol,
int(*)(double, double, double, double *)  ExactSolution,
const double *  x,
const double *  y,
const double *  z,
double *  Norm 
) const [inline, virtual]

Computes the norm of the error over an element.

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 206 of file Galeri_GalerkinVariational.h.

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::LHS ( const double  Phi,
const double  Psi,
const double  PhiX,
const double  PsiX,
const double  PhiY,
const double  PsiY,
const double  PhiZ,
const double  PsiZ,
const double  x,
const double  y,
const double  z 
) const [inline, virtual]

Evaluates the left-hand side at point (x, y, z).

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 248 of file Galeri_GalerkinVariational.h.

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::RHS ( const double  Psi,
const double  PsiX,
const double  PsiY,
const double  PsiZ,
const double  x,
const double  y,
const double  z 
) const [inline, virtual]

Evaluates the right-hand side at point (x, y, z).

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 261 of file Galeri_GalerkinVariational.h.

template<class T >
int Galeri::FiniteElements::GalerkinVariational< T >::BC ( const int  PatchID  )  const [inline, virtual]

Returns the boundary condition type of the specified patch.

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 269 of file Galeri_GalerkinVariational.h.

template<class T >
double Galeri::FiniteElements::GalerkinVariational< T >::BC ( const double  x,
const double  y,
const double  z,
const int  PatchID 
) const [inline, virtual]

Returns the value of the boundary condition at point (x, y, z).

Implements Galeri::FiniteElements::AbstractVariational.

Definition at line 275 of file Galeri_GalerkinVariational.h.


Member Data Documentation

template<class T >
double(* Galeri::FiniteElements::GalerkinVariational< T >::diff_)(const double &x, const double &y, const double &z) [private]

Definition at line 281 of file Galeri_GalerkinVariational.h.

template<class T >
double(* Galeri::FiniteElements::GalerkinVariational< T >::source_)(const double &x, const double &y, const double &z) [private]

Definition at line 282 of file Galeri_GalerkinVariational.h.

template<class T >
double(* Galeri::FiniteElements::GalerkinVariational< T >::force_)(const double &x, const double &y, const double &z) [private]

Definition at line 283 of file Galeri_GalerkinVariational.h.

template<class T >
double(* Galeri::FiniteElements::GalerkinVariational< T >::bc_)(const double &x, const double &y, const double &z, const int &Patch) [private]

Definition at line 284 of file Galeri_GalerkinVariational.h.

template<class T >
int(* Galeri::FiniteElements::GalerkinVariational< T >::bc_type_)(const int &Patch) [private]

Definition at line 285 of file Galeri_GalerkinVariational.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Friends Defines
Generated on Wed Apr 13 10:08:41 2011 for Galeri Package Browser (Single Doxygen Collection) by  doxygen 1.6.3