| 420 | } // fixMassLoss3PhaseFlows |
| 421 | |
| 422 | std::vector<double> |
| 423 | computeHeavisideIntegrals2PhaseFlows(const LevelSetContainer& lsc) |
| 424 | { |
| 425 | const double ncells = lsc.getInterfaceHalfWidth(); |
| 426 | Pointer<AdvDiffHierarchyIntegrator> adv_diff_integrator = lsc.getAdvDiffHierarchyIntegrator(); |
| 427 | Pointer<PatchHierarchy<NDIM>> patch_hier = adv_diff_integrator->getPatchHierarchy(); |
| 428 | Pointer<HierarchyMathOps> hier_math_ops = adv_diff_integrator->getHierarchyMathOps(); |
| 429 | |
| 430 | // NOTE: In practice the level set mass is computed after integrating the hierarchy. Hence the application time |
| 431 | // would be the new time and the variable context would be the current context. |
| 432 | VariableDatabase<NDIM>* var_db = VariableDatabase<NDIM>::getDatabase(); |
| 433 | const int ls_idx = |
| 434 | var_db->mapVariableAndContextToIndex(lsc.getLevelSetVariable(), adv_diff_integrator->getCurrentContext()); |
| 435 | |
| 436 | std::vector<double> integrals = compute_heaviside_integrals(hier_math_ops, ls_idx, ncells); |
| 437 | |
| 438 | return integrals; |
| 439 | |
| 440 | } // computeHeavisideIntegrals2PhaseFlows |
| 441 | |
| 442 | std::vector<double> |
| 443 | computeHeavisideIntegrals3PhaseFlows(const LevelSetContainer& lsc) |
nothing calls this directly
no test coverage detected