Rheolef  7.2
an efficient C++ finite element environment
 
Loading...
Searching...
No Matches
piola_fem_hdiv.cc
Go to the documentation of this file.
1
21//
22// Piola transformation for H(div,omega) approximations
23//
24// author: Pierre.Saramito@imag.fr
25//
26// date: 9 may 2019
27//
28// references:
29// [1] P.-A. Raviart and J.-M. Thomas.
30// A mixed finite element method for 2-nd order elliptic problems.
31// in "Mathematical aspects of finite element methods",
32// pages 292--315, Springer, 1977.
33// [2] J. E. Roberts and J.-M. Thomas,
34// Mixed and hybrid methods,
35// In "Handbook of numerical analysis. Volume 2.
36// Finite element methods (part 1)",
37// chapter 4, Elsevier, 1991.
38// see page 554
39//
40#include "piola_fem_hdiv.h"
42namespace rheolef {
43
44template<class T>
45void
47 const piola<T>& p,
48 const point_basic<T>& hat_u_in,
49 point_basic<T>& u) const
50{
51 point_basic<T> hat_u = hat_u_in; // avoid the aliasing problem (u,hat_u)
52 u = (1/p.detDF)*(p.DF*hat_u); // TODO: DVT_OPTIM_2D
53}
54template<class T>
55void
57 const piola<T>& p,
58 const point_basic<T>& u_in,
59 point_basic<T>& hat_u) const
60{
61 point_basic<T> u = u_in; // avoid the aliasing problem (u,hat_u)
62 hat_u = p.detDF*(p.invDF*u); // TODO: DVT_OPTIM_2D
63}
64template<class T>
65void
67 const piola<T>& p,
68 const point_basic<T>& hat_u_in,
69 const tensor_basic<T>& hat_grad_u_in,
72{
73 point_basic<T> hat_u = hat_u_in; // avoid the aliasing problem (u,hat_u)
74 tensor_basic<T> hat_grad_u = hat_grad_u_in;
75 grad_u = (1/p.detDF)*p.DF*hat_grad_u*p.invDF; // TODO: DVT_OPTIM_2D
77 transform (p, hat_u, u); // TODO: used only in the axi case: could be optimized
78 grad_post (p, gopt, u, grad_u);
79}
80// ----------------------------------------------------------------------------
81// instanciation in library
82// ----------------------------------------------------------------------------
83#define _RHEOLEF_instanciation(T) \
84template class piola_fem_hdiv<T>; \
85
87
88}// namespace rheolef
#define _RHEOLEF_instanciation(T, M, A)
Definition asr.cc:223
see the Float page for the full documentation
void inv_transform(const piola< T > &p, const point_basic< T > &u, point_basic< T > &hat_u) const
void transform(const piola< T > &p, const point_basic< T > &hat_u, point_basic< T > &u) const
void grad_transform(const piola< T > &p, const point_basic< T > &hat_u, const tensor_basic< T > &hat_grad_u, const details::differentiate_option &gopt, tensor_basic< T > &grad_u) const
This file is part of Rheolef.
Definition sphere.icc:25
Definition leveque.h:25