refactor(poly): updated header guards to pragma once
This commit is contained in:
@@ -22,15 +22,10 @@
|
||||
#include <cmath>
|
||||
|
||||
#include "integrators.h"
|
||||
#include "debug.h"
|
||||
|
||||
|
||||
namespace polyMFEMUtils {
|
||||
NonlinearPowerIntegrator::NonlinearPowerIntegrator(
|
||||
mfem::Coefficient &coeff,
|
||||
double n) :
|
||||
|
||||
m_coeff(coeff),
|
||||
NonlinearPowerIntegrator::NonlinearPowerIntegrator(const double n) :
|
||||
m_polytropicIndex(n) {}
|
||||
|
||||
void NonlinearPowerIntegrator::AssembleElementVector(
|
||||
@@ -60,9 +55,7 @@ namespace polyMFEMUtils {
|
||||
double u_safe = std::max(u_val, 0.0);
|
||||
double u_nl = std::pow(u_safe, m_polytropicIndex);
|
||||
|
||||
// double coeff_val = m_coeff.Eval(Trans, ip);
|
||||
double coeff_val = 1.0;
|
||||
double x2_u_nl = coeff_val * u_nl;
|
||||
double x2_u_nl = u_nl;
|
||||
|
||||
for (int i = 0; i < dof; i++){
|
||||
elvect(i) += shape(i) * x2_u_nl * weight;
|
||||
@@ -95,13 +88,10 @@ namespace polyMFEMUtils {
|
||||
for (int j = 0; j < dof; j++) {
|
||||
u_val += elfun(j) * shape(j);
|
||||
}
|
||||
// double coeff_val = m_coeff.Eval(Trans, ip);
|
||||
double coeff_val = 1.0;
|
||||
|
||||
|
||||
|
||||
// Calculate the Jacobian
|
||||
double u_safe = std::max(u_val, 0.0);
|
||||
double d_u_nl = coeff_val * m_polytropicIndex * std::pow(u_safe, m_polytropicIndex - 1);
|
||||
double d_u_nl = m_polytropicIndex * std::pow(u_safe, m_polytropicIndex - 1);
|
||||
double x2_d_u_nl = d_u_nl;
|
||||
|
||||
for (int i = 0; i < dof; i++) {
|
||||
|
||||
Reference in New Issue
Block a user