Skip to content

Commit

Permalink
Merge pull request #1042 from jeffriley/issue-1034
Browse files Browse the repository at this point in the history
Issue 1034 - change calls to CalculateMomentOfInertia() to CalculateMomentOfInertiaAU()
  • Loading branch information
jeffriley authored Dec 27, 2023
2 parents 0ff9d12 + 6def95c commit 5167070
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/BaseBinaryStar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,8 @@ void BaseBinaryStar::SetRemainingValues() {
m_SemiMajorAxisAtDCOFormation = DEFAULT_INITIAL_DOUBLE_VALUE;
m_EccentricityAtDCOFormation = DEFAULT_INITIAL_DOUBLE_VALUE;

double momentOfInertia1 = m_Star1->CalculateMomentOfInertia();
double momentOfInertia2 = m_Star2->CalculateMomentOfInertia();
double momentOfInertia1 = m_Star1->CalculateMomentOfInertiaAU();
double momentOfInertia2 = m_Star2->CalculateMomentOfInertiaAu();

m_TotalEnergy = CalculateTotalEnergy(m_SemiMajorAxis, m_Star1->Mass(), m_Star2->Mass(), m_Star1->Omega(), m_Star2->Omega(), momentOfInertia1, momentOfInertia2);

Expand Down
2 changes: 1 addition & 1 deletion src/BaseStar.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class BaseStar {

// getters - alphabetically
double Age() const { return m_Age; }
double AngularMomentum() const { return CalculateMomentOfInertia() * m_Omega; }
double AngularMomentum() const { return CalculateMomentOfInertiaAU() * m_Omega; }
double BindingEnergy_Fixed() const { return m_BindingEnergies.fixed; }
double BindingEnergy_Nanjing() const { return m_BindingEnergies.nanjing; }
double BindingEnergy_Loveridge() const { return m_BindingEnergies.loveridge; }
Expand Down

0 comments on commit 5167070

Please sign in to comment.