|
template<int DIM, bool CALCULATE_DIRVATIVES> |
MoFEMErrorCode | calculate (int p, int nb_integration_pts, int n0_idx, int n1_idx, double n[], FTensor::Tensor1< double, 3 > t_grad_n[], FTensor::Tensor1< FTensor::PackPtr< double *, 3 >, 3 > &t_phi, FTensor::Tensor2< FTensor::PackPtr< double *, 3 *DIM >, 3, DIM > *t_diff_phi_ptr) |
|
Definition at line 1978 of file Hcurl.cpp.
◆ calculate()
template<int DIM, bool CALCULATE_DIRVATIVES>
MoFEMErrorCode HcurlEdgeBase::calculate |
( |
int |
p, |
|
|
int |
nb_integration_pts, |
|
|
int |
n0_idx, |
|
|
int |
n1_idx, |
|
|
double |
n[], |
|
|
FTensor::Tensor1< double, 3 > |
t_grad_n[], |
|
|
FTensor::Tensor1< FTensor::PackPtr< double *, 3 >, 3 > & |
t_phi, |
|
|
FTensor::Tensor2< FTensor::PackPtr< double *, 3 *DIM >, 3, DIM > * |
t_diff_phi_ptr |
|
) |
| |
|
inline |
Definition at line 1991 of file Hcurl.cpp.
2011 for (
int gg = 0; gg != nb_integration_pts; ++gg) {
2013 const int shift_n = (DIM + 1) * gg;
2014 const double n0 =
n[shift_n + n0_idx];
2015 const double n1 =
n[shift_n + n1_idx];
2017 tPhi0(
i) = n0 * t_grad_n1(
i) - n1 * t_grad_n0(
i);
2022 if (CALCULATE_DIRVATIVES) {
2025 t_grad_n0(
j) * t_grad_n1(
i) - t_grad_n1(
j) * t_grad_n0(
i);
2026 (*t_diff_phi_ptr)(
i,
j) = t_diff_phi0(
i,
j);
2027 ++(*t_diff_phi_ptr);
2032 if (CALCULATE_DIRVATIVES)
2035 &*
diffFi.data().begin(), DIM);
2038 &*
fI.data().begin(),
nullptr, DIM);
2043 for (
int oo = 1; oo <= p - 1; ++oo) {
2045 const double b = pow(n0 + n1, oo);
2048 if (CALCULATE_DIRVATIVES) {
2051 oo * pow(n0 + n1, oo - 1) * (t_grad_n0(
i) + t_grad_n1(
i));
2052 (*t_diff_phi_ptr)(
i,
j) = (b *
fI[oo]) * t_diff_phi0(
i,
j) +
2053 (b * t_diff_fi(
j)) *
tPhi0(
i) +
2056 ++(*t_diff_phi_ptr);
◆ diffFi
MatrixDouble HcurlEdgeBase::diffFi |
◆ fI
VectorDouble HcurlEdgeBase::fI |
◆ tDiffb
◆ tGradN0pN1
◆ tPhi0
The documentation for this struct was generated from the following file:
PetscErrorCode Jacobi_polynomials(int p, double alpha, double x, double t, double *diff_x, double *diff_t, double *L, double *diffL, const int dim)
Calculate Jacobi approximation basis.