feat(polySolver): added polytropic index as a constructor argument for polytrope operator

This commit is contained in:
2025-05-12 14:27:41 -04:00
parent 1ee919a4a9
commit 534a9cdf4b

View File

@@ -119,7 +119,8 @@ void PolySolver::assembleBlockSystem() {
std::move(forms->Q),
std::move(forms->D),
std::move(forms->f),
blockOffsets);
blockOffsets,
m_polytropicIndex);
}
mfem::Array<int> PolySolver::computeBlockOffsets() const {
@@ -270,7 +271,7 @@ void PolySolver::setInitialGuess() const {
// return (-1.0/radius) * r + 1;
// return -std::pow((u*r), 2)+1.0; // The series expansion is a better guess; however, this is cheaper and ensures that the value at the surface is very close to zero in a way that the series expansion does not
return laneEmden::thetaSeriesExpansion(r, m_polytropicIndex, 10) + 3.0;
return laneEmden::thetaSeriesExpansion(r, m_polytropicIndex, 10);
}
);