Skip to content

Commit

Permalink
Rename for clarity and consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastiangrimberg committed Apr 25, 2024
1 parent f639cc9 commit cd99f8f
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion palace/drivers/electrostaticsolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ void ElectrostaticSolver::PostprocessTerminals(
for (int i = 0; i < C.Height(); i++)
{
// Diagonal: Cᵢᵢ = 2 Uₑ(Vᵢ) / Vᵢ² = (Vᵢᵀ K Vᵢ) / Vᵢ²
auto &V_gf = postop.GetV().Real();
auto &V_gf = postop.GetVGridFunction().Real();
auto &D_gf = postop.GetDomainPostOp().D;
V_gf.SetFromTrueDofs(V[i]);
postop.GetDomainPostOp().M_elec->Mult(V_gf, D_gf);
Expand Down
2 changes: 1 addition & 1 deletion palace/drivers/magnetostaticsolver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ void MagnetostaticSolver::PostprocessTerminals(PostOperator &postop,
for (int i = 0; i < M.Height(); i++)
{
// Diagonal: Mᵢᵢ = 2 Uₘ(Aᵢ) / Iᵢ² = (Aᵢᵀ K Aᵢ) / Iᵢ²
auto &A_gf = postop.GetA().Real();
auto &A_gf = postop.GetAGridFunction().Real();
auto &H_gf = postop.GetDomainPostOp().H;
A_gf.SetFromTrueDofs(A[i]);
postop.GetDomainPostOp().M_mag->Mult(A_gf, H_gf);
Expand Down
8 changes: 4 additions & 4 deletions palace/models/postoperator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,25 +97,25 @@ class PostOperator
void SetAGridFunction(const Vector &a, bool exchange_face_nbr_data = true);

// Access grid functions for field solutions.
auto &GetE()
auto &GetEGridFunction()
{
MFEM_ASSERT(E.has_value(),
"Missing GridFunction object when accessing from PostOperator!");
return *E;
}
auto &GetB()
auto &GetBGridFunction()
{
MFEM_ASSERT(B.has_value(),
"Missing GridFunction object when accessing from PostOperator!");
return *B;
}
auto &GetV()
auto &GetVGridFunction()
{
MFEM_ASSERT(V.has_value(),
"Missing GridFunction object when accessing from PostOperator!");
return *V;
}
auto &GetA()
auto &GetAGridFunction()
{
MFEM_ASSERT(A.has_value(),
"Missing GridFunction object when accessing from PostOperator!");
Expand Down

0 comments on commit cd99f8f

Please sign in to comment.