| 1 |
// @HEADER |
| 2 |
// ***************************************************************************** |
| 3 |
// Rapid Optimization Library (ROL) Package |
| 4 |
// |
| 5 |
// Copyright 2014 NTESS and the ROL contributors. |
| 6 |
// SPDX-License-Identifier: BSD-3-Clause |
| 7 |
// ***************************************************************************** |
| 8 |
// @HEADER |
| 9 |
|
| 10 |
/*! \file pde.hpp |
| 11 |
\brief Implements the local PDE interface for the Poisson-Boltzmann control problem. |
| 12 |
*/ |
| 13 |
|
| 14 |
#ifndef PDE_PARABOLIC_SEMILINEAR_HPP |
| 15 |
#define PDE_PARABOLIC_SEMILINEAR_HPP |
| 16 |
|
| 17 |
#include "../../TOOLS/pde.hpp" |
| 18 |
#include "../../TOOLS/fe.hpp" |
| 19 |
|
| 20 |
#include "Intrepid_HGRAD_QUAD_C1_FEM.hpp" |
| 21 |
#include "Intrepid_HGRAD_QUAD_C2_FEM.hpp" |
| 22 |
#include "Intrepid_DefaultCubatureFactory.hpp" |
| 23 |
#include "Intrepid_FunctionSpaceTools.hpp" |
| 24 |
#include "Intrepid_CellTools.hpp" |
| 25 |
|
| 26 |
#include "ROL_Ptr.hpp" |
| 27 |
|
| 28 |
template <class Real> |
| 29 |
class PDE_Semilinear : public PDE<Real> { |
| 30 |
private: |
| 31 |
// Finite element basis information |
| 32 |
ROL::Ptr<Intrepid::Basis<Real, Intrepid::FieldContainer<Real>>> basisPtr_; |
| 33 |
std::vector<ROL::Ptr<Intrepid::Basis<Real, Intrepid::FieldContainer<Real>>>> basisPtrs_; |
| 34 |
// Cell cubature information |
| 35 |
ROL::Ptr<Intrepid::Cubature<Real>> cellCub_; |
| 36 |
// Finite element definition |
| 37 |
ROL::Ptr<FE<Real>> fe_vol_; |
| 38 |
|
| 39 |
int type_; |
| 40 |
|
| 41 |
public: |
| 42 |
PDE_Semilinear(Teuchos::ParameterList &parlist) { |
| 43 |
// Finite element fields. |
| 44 |
int basisOrder = parlist.sublist("Semilinear").get("Order of FE discretization",1); |
| 45 |
if (basisOrder == 1) { |
| 46 |
basisPtr_ = ROL::makePtr<Intrepid::Basis_HGRAD_QUAD_C1_FEM<Real, Intrepid::FieldContainer<Real>>>(); |
| 47 |
} |
| 48 |
else if (basisOrder == 2) { |
| 49 |
basisPtr_ = ROL::makePtr<Intrepid::Basis_HGRAD_QUAD_C2_FEM<Real, Intrepid::FieldContainer<Real>>>(); |
| 50 |
} |
| 51 |
basisPtrs_.clear(); basisPtrs_.push_back(basisPtr_); |
| 52 |
// Quadrature rules. |
| 53 |
shards::CellTopology cellType = basisPtr_->getBaseCellTopology(); // get the cell type from any basis |
| 54 |
Intrepid::DefaultCubatureFactory<Real> cubFactory; // create cubature factory |
| 55 |
int cubDegree = parlist.sublist("Semilinear").get("Cubature Degree",2); // set cubature degree, e.g., 2 |
| 56 |
cellCub_ = cubFactory.create(cellType, cubDegree); // create default cubature |
| 57 |
|
| 58 |
type_ = parlist.sublist("Semilinear").get("Nonlinearity Type",0); |
| 59 |
} |
| 60 |
|
| 61 |
void residual(ROL::Ptr<Intrepid::FieldContainer<Real>> & res, |
| 62 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 63 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 64 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 65 |
// GET DIMENSIONS |
| 66 |
const int c = fe_vol_->gradN()->dimension(0); |
| 67 |
const int f = fe_vol_->gradN()->dimension(1); |
| 68 |
const int p = fe_vol_->gradN()->dimension(2); |
| 69 |
const int d = fe_vol_->gradN()->dimension(3); |
| 70 |
// INITIALIZE RESIDUAL |
| 71 |
res = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f); |
| 72 |
// COMPUTE PDE COEFFICIENTS |
| 73 |
Intrepid::FieldContainer<Real> diff(c, p), adv(c, p, d), rhs(c, p); |
| 74 |
computeCoefficients(diff,adv,rhs); |
| 75 |
// Evaluate PDE solution |
| 76 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valU_eval = |
| 77 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 78 |
fe_vol_->evaluateValue(valU_eval, u_coeff); |
| 79 |
ROL::Ptr<Intrepid::FieldContainer<Real>> gradU_eval = |
| 80 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p, d); |
| 81 |
fe_vol_->evaluateGradient(gradU_eval, u_coeff); |
| 82 |
// Evaluate control |
| 83 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valZ_eval = |
| 84 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 85 |
fe_vol_->evaluateValue(valZ_eval, z_coeff); |
| 86 |
// Multiply diff * grad(U) |
| 87 |
Intrepid::FieldContainer<Real> diff_gradU(c, p, d); |
| 88 |
Intrepid::FunctionSpaceTools::tensorMultiplyDataData<Real>(diff_gradU, |
| 89 |
diff, |
| 90 |
*gradU_eval); |
| 91 |
// Integrate (diff * grad(U)) . grad(N) |
| 92 |
Intrepid::FunctionSpaceTools::integrate<Real>(*res, |
| 93 |
diff_gradU, |
| 94 |
*(fe_vol_->gradNdetJ()), |
| 95 |
Intrepid::COMP_CPP, false); |
| 96 |
// Multiply adv . grad(U) |
| 97 |
Intrepid::FieldContainer<Real> adv_gradU(c, p); |
| 98 |
Intrepid::FunctionSpaceTools::dotMultiplyDataData<Real>(adv_gradU, |
| 99 |
adv, |
| 100 |
*gradU_eval); |
| 101 |
// Integrate (adv . grad(U)) * N |
| 102 |
Intrepid::FunctionSpaceTools::integrate<Real>(*res, |
| 103 |
adv_gradU, |
| 104 |
*(fe_vol_->NdetJ()), |
| 105 |
Intrepid::COMP_CPP, true); |
| 106 |
// Integrate L * N |
| 107 |
Intrepid::FunctionSpaceTools::integrate<Real>(*res, |
| 108 |
rhs, |
| 109 |
(*fe_vol_->NdetJ()), |
| 110 |
Intrepid::COMP_CPP, true); |
| 111 |
// Compute F(U) |
| 112 |
Intrepid::FieldContainer<Real> phi_valU_eval(c, p); |
| 113 |
for (int i = 0; i < c; ++i) { |
| 114 |
for (int j = 0; j < p; ++j) { |
| 115 |
phi_valU_eval(i,j) = evaluateReaction((*valU_eval)(i,j),0); |
| 116 |
} |
| 117 |
} |
| 118 |
// Integrate F(U) * N |
| 119 |
Intrepid::FunctionSpaceTools::integrate<Real>(*res, |
| 120 |
phi_valU_eval, |
| 121 |
*(fe_vol_->NdetJ()), |
| 122 |
Intrepid::COMP_CPP, true); |
| 123 |
// Integrate -Z *N |
| 124 |
Intrepid::FieldContainer<Real> valZ_scal(c, p); |
| 125 |
Intrepid::RealSpaceTools<Real>::scale(valZ_scal,*valZ_eval,static_cast<Real>(-1)); |
| 126 |
Intrepid::FunctionSpaceTools::integrate<Real>(*res, |
| 127 |
valZ_scal, |
| 128 |
*(fe_vol_->NdetJ()), |
| 129 |
Intrepid::COMP_CPP, true); |
| 130 |
} |
| 131 |
|
| 132 |
void Jacobian_1(ROL::Ptr<Intrepid::FieldContainer<Real>> & jac, |
| 133 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 134 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 135 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 136 |
// GET DIMENSIONS |
| 137 |
const int c = fe_vol_->gradN()->dimension(0); |
| 138 |
const int f = fe_vol_->gradN()->dimension(1); |
| 139 |
const int p = fe_vol_->gradN()->dimension(2); |
| 140 |
const int d = fe_vol_->gradN()->dimension(3); |
| 141 |
// INITIALIZE JACOBIAN |
| 142 |
jac = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f, f); |
| 143 |
// COMPUTE PDE COEFFICIENTS |
| 144 |
Intrepid::FieldContainer<Real> diff(c, p), adv(c, p, d), rhs(c, p); |
| 145 |
computeCoefficients(diff,adv,rhs); |
| 146 |
// Evaluate PDE solution |
| 147 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valU_eval = |
| 148 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 149 |
fe_vol_->evaluateValue(valU_eval, u_coeff); |
| 150 |
// Evaluate control |
| 151 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valZ_eval = |
| 152 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 153 |
fe_vol_->evaluateValue(valZ_eval, z_coeff); |
| 154 |
// Multiply diff * grad(N) |
| 155 |
Intrepid::FieldContainer<Real> diff_gradN(c, f, p, d); |
| 156 |
Intrepid::FunctionSpaceTools::tensorMultiplyDataField<Real>(diff_gradN, |
| 157 |
diff, |
| 158 |
*(fe_vol_->gradN())); |
| 159 |
// Integrate (diff * grad(N)) . grad(N) |
| 160 |
Intrepid::FunctionSpaceTools::integrate<Real>(*jac, |
| 161 |
diff_gradN, |
| 162 |
*(fe_vol_->gradNdetJ()), |
| 163 |
Intrepid::COMP_CPP, false); |
| 164 |
// Multiply adv . grad(N) |
| 165 |
Intrepid::FieldContainer<Real> adv_gradN(c, f, p); |
| 166 |
Intrepid::FunctionSpaceTools::dotMultiplyDataField<Real>(adv_gradN, |
| 167 |
adv, |
| 168 |
*(fe_vol_->gradN())); |
| 169 |
// Integrate (adv . grad(N)) * N |
| 170 |
Intrepid::FunctionSpaceTools::integrate<Real>(*jac, |
| 171 |
adv_gradN, |
| 172 |
*(fe_vol_->NdetJ()), |
| 173 |
Intrepid::COMP_CPP, true); |
| 174 |
// Compute F'(U) * N |
| 175 |
Intrepid::FieldContainer<Real> dphi_valU_eval(c, p); |
| 176 |
Intrepid::FieldContainer<Real> NdphiU(c, f, p); |
| 177 |
for (int i = 0; i < c; ++i) { |
| 178 |
for (int j = 0; j < p; ++j) { |
| 179 |
dphi_valU_eval(i,j) = evaluateReaction((*valU_eval)(i,j),1); |
| 180 |
} |
| 181 |
} |
| 182 |
Intrepid::FunctionSpaceTools::scalarMultiplyDataField<Real>(NdphiU, |
| 183 |
dphi_valU_eval, |
| 184 |
*(fe_vol_->N())); |
| 185 |
// Integrate F'(U) * N * N |
| 186 |
Intrepid::FunctionSpaceTools::integrate<Real>(*jac, |
| 187 |
NdphiU, |
| 188 |
*(fe_vol_->NdetJ()), |
| 189 |
Intrepid::COMP_CPP, true); |
| 190 |
} |
| 191 |
|
| 192 |
void Jacobian_2(ROL::Ptr<Intrepid::FieldContainer<Real>> & jac, |
| 193 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 194 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 195 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 196 |
// GET DIMENSIONS |
| 197 |
const int c = fe_vol_->gradN()->dimension(0); |
| 198 |
const int f = fe_vol_->gradN()->dimension(1); |
| 199 |
const int p = fe_vol_->gradN()->dimension(2); |
| 200 |
// INITIALIZE JACOBIAN |
| 201 |
jac = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f, f); |
| 202 |
// ADD CONTROL TERM |
| 203 |
Intrepid::FieldContainer<Real> valN_scal(c, f, p); |
| 204 |
Intrepid::RealSpaceTools<Real>::scale(valN_scal,*(fe_vol_->N()),static_cast<Real>(-1)); |
| 205 |
Intrepid::FunctionSpaceTools::integrate<Real>(*jac, |
| 206 |
valN_scal, |
| 207 |
*(fe_vol_->NdetJ()), |
| 208 |
Intrepid::COMP_CPP, false); |
| 209 |
} |
| 210 |
|
| 211 |
void Hessian_11(ROL::Ptr<Intrepid::FieldContainer<Real>> & hess, |
| 212 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & l_coeff, |
| 213 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 214 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 215 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 216 |
// GET DIMENSIONS |
| 217 |
const int c = fe_vol_->gradN()->dimension(0); |
| 218 |
const int f = fe_vol_->gradN()->dimension(1); |
| 219 |
const int p = fe_vol_->gradN()->dimension(2); |
| 220 |
// INITIALIZE HESSIAN |
| 221 |
hess = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f, f); |
| 222 |
// COMPUTE NONLINEAR TERM |
| 223 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valU_eval = |
| 224 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 225 |
fe_vol_->evaluateValue(valU_eval, u_coeff); |
| 226 |
ROL::Ptr<Intrepid::FieldContainer<Real>> valL_eval = |
| 227 |
ROL::makePtr<Intrepid::FieldContainer<Real>>(c, p); |
| 228 |
fe_vol_->evaluateValue(valL_eval, l_coeff); |
| 229 |
Intrepid::FieldContainer<Real> d2phi_valU_eval(c, p); |
| 230 |
for (int i = 0; i < c; ++i) { |
| 231 |
for (int j = 0; j < p; ++j) { |
| 232 |
d2phi_valU_eval(i,j) = (*valL_eval)(i,j)*evaluateReaction((*valU_eval)(i,j),2); |
| 233 |
} |
| 234 |
} |
| 235 |
Intrepid::FieldContainer<Real> NLd2phiU(c,f,p); |
| 236 |
Intrepid::FunctionSpaceTools::scalarMultiplyDataField<Real>(NLd2phiU, |
| 237 |
d2phi_valU_eval, |
| 238 |
*(fe_vol_->N())); |
| 239 |
Intrepid::FunctionSpaceTools::integrate<Real>(*hess, |
| 240 |
NLd2phiU, |
| 241 |
*(fe_vol_->NdetJ()), |
| 242 |
Intrepid::COMP_CPP, false); |
| 243 |
} |
| 244 |
|
| 245 |
void Hessian_12(ROL::Ptr<Intrepid::FieldContainer<Real>> & hess, |
| 246 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & l_coeff, |
| 247 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 248 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 249 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 250 |
throw Exception::Zero(">>> (PDE_Semilinear:Hessian_12: Hessian is zero."); |
| 251 |
} |
| 252 |
|
| 253 |
void Hessian_21(ROL::Ptr<Intrepid::FieldContainer<Real>> & hess, |
| 254 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & l_coeff, |
| 255 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 256 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 257 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 258 |
throw Exception::Zero(">>> (PDE_Semilinear:Hessian_21: Hessian is zero."); |
| 259 |
} |
| 260 |
|
| 261 |
void Hessian_22(ROL::Ptr<Intrepid::FieldContainer<Real>> & hess, |
| 262 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & l_coeff, |
| 263 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & u_coeff, |
| 264 |
const ROL::Ptr<const Intrepid::FieldContainer<Real>> & z_coeff = ROL::nullPtr, |
| 265 |
const ROL::Ptr<const std::vector<Real>> & z_param = ROL::nullPtr) { |
| 266 |
throw Exception::Zero(">>> (PDE_Semilinear:Hessian_22: Hessian is zero."); |
| 267 |
} |
| 268 |
|
| 269 |
void RieszMap_1(ROL::Ptr<Intrepid::FieldContainer<Real>> & riesz) { |
| 270 |
// GET DIMENSIONS |
| 271 |
const int c = fe_vol_->N()->dimension(0); |
| 272 |
const int f = fe_vol_->N()->dimension(1); |
| 273 |
// INITIALIZE RIESZ |
| 274 |
riesz = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f, f); |
| 275 |
//*riesz = *fe_vol_->stiffMat(); |
| 276 |
//Intrepid::RealSpaceTools<Real>::add(*riesz,*(fe_vol_->massMat())); |
| 277 |
*riesz = *fe_vol_->massMat(); |
| 278 |
} |
| 279 |
|
| 280 |
void RieszMap_2(ROL::Ptr<Intrepid::FieldContainer<Real>> & riesz) { |
| 281 |
// GET DIMENSIONS |
| 282 |
const int c = fe_vol_->N()->dimension(0); |
| 283 |
const int f = fe_vol_->N()->dimension(1); |
| 284 |
// INITIALIZE RIESZ |
| 285 |
riesz = ROL::makePtr<Intrepid::FieldContainer<Real>>(c, f, f); |
| 286 |
//*riesz = *fe_vol_->stiffMat(); |
| 287 |
//Intrepid::RealSpaceTools<Real>::add(*riesz,*(fe_vol_->massMat())); |
| 288 |
*riesz = *fe_vol_->massMat(); |
| 289 |
} |
| 290 |
|
| 291 |
std::vector<ROL::Ptr<Intrepid::Basis<Real, Intrepid::FieldContainer<Real>>>> getFields() { |
| 292 |
return basisPtrs_; |
| 293 |
} |
| 294 |
|
| 295 |
void setCellNodes(const ROL::Ptr<Intrepid::FieldContainer<Real>> &volCellNodes, |
| 296 |
const std::vector<std::vector<ROL::Ptr<Intrepid::FieldContainer<Real>>>> &bdryCellNodes, |
| 297 |
const std::vector<std::vector<std::vector<int>>> &bdryCellLocIds) { |
| 298 |
// Finite element definition. |
| 299 |
fe_vol_ = ROL::makePtr<FE<Real>>(volCellNodes,basisPtr_,cellCub_); |
| 300 |
} |
| 301 |
|
| 302 |
const ROL::Ptr<FE<Real>> getFE(void) const { |
| 303 |
return fe_vol_; |
| 304 |
} |
| 305 |
|
| 306 |
private: |
| 307 |
|
| 308 |
Real evaluateDiffusivity(const std::vector<Real> &x) const { |
| 309 |
return static_cast<Real>(1.e-1); |
| 310 |
} |
| 311 |
|
| 312 |
void evaluateAdvection(std::vector<Real> &v, const std::vector<Real> &x) const { |
| 313 |
const Real a(2.5), b(7.5); |
| 314 |
v[0] = b - a*x[0]; |
| 315 |
v[1] = a*x[1]; |
| 316 |
} |
| 317 |
|
| 318 |
Real evaluateLoad(const std::vector<Real> &x) const { |
| 319 |
const int dim = x.size(); |
| 320 |
const Real zero(0), center(0.1), one(1), rad(0.07); |
| 321 |
Real norm(0); |
| 322 |
for (int i = 0; i < dim; ++i) { |
| 323 |
norm += std::pow(x[i]-center,2); |
| 324 |
} |
| 325 |
norm = std::sqrt(norm); |
| 326 |
return (norm < rad ? one : zero); |
| 327 |
} |
| 328 |
|
| 329 |
void computeCoefficients(Intrepid::FieldContainer<Real> &diff, |
| 330 |
Intrepid::FieldContainer<Real> &adv, |
| 331 |
Intrepid::FieldContainer<Real> &rhs) const { |
| 332 |
// GET DIMENSIONS |
| 333 |
const int c = fe_vol_->gradN()->dimension(0); |
| 334 |
const int p = fe_vol_->gradN()->dimension(2); |
| 335 |
const int d = fe_vol_->gradN()->dimension(3); |
| 336 |
std::vector<Real> pt(d), vel(d); |
| 337 |
for (int i = 0; i < c; ++i) { |
| 338 |
for (int j = 0; j < p; ++j) { |
| 339 |
for ( int k = 0; k < d; ++k) { |
| 340 |
pt[k] = (*fe_vol_->cubPts())(i,j,k); |
| 341 |
} |
| 342 |
// Compute scaled Debye length |
| 343 |
diff(i,j) = evaluateDiffusivity(pt); |
| 344 |
// Compute advection velocity field V |
| 345 |
evaluateAdvection(vel,pt); |
| 346 |
for (int k = 0; k < d; ++k) { |
| 347 |
adv(i,j,k) = adv[k]; |
| 348 |
} |
| 349 |
// Compute forcing term f |
| 350 |
rhs(i,j) = -evaluateLoad(pt); |
| 351 |
} |
| 352 |
} |
| 353 |
} |
| 354 |
|
| 355 |
Real evaluateReaction(const Real u, const int deriv = 0) const { |
| 356 |
const Real zero(0), one(1), three(3), six(6); |
| 357 |
Real val(0); |
| 358 |
if (type_ == 0) { |
| 359 |
val = (deriv == 0 ? u : (deriv == 1 ? one : zero)); |
| 360 |
} |
| 361 |
else if (type_ == 1) { |
| 362 |
val = (deriv == 0 ? std::pow(u, 3) - u |
| 363 |
: (deriv == 1 ? three * std::pow(u, 2) - one |
| 364 |
: six * u)); |
| 365 |
} |
| 366 |
else if (type_ == 2) { |
| 367 |
val = (deriv == 0 ? std::exp(u) - std::exp(-u) |
| 368 |
: (deriv == 1 ? std::exp(u) + std::exp(-u) |
| 369 |
: std::exp(u) - std::exp(-u))); |
| 370 |
} |
| 371 |
else { |
| 372 |
val = (deriv == 0 ? u : (deriv == 1 ? one : zero)); |
| 373 |
} |
| 374 |
return val; |
| 375 |
} |
| 376 |
}; // PDE_Semilinear |
| 377 |
|
| 378 |
#endif |