Skip to content

Commit 56467ea

Browse files
committed
Consistently order what functions return.
1 parent 6b56db6 commit 56467ea

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

include/aspect/boundary_temperature/dynamic_core.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -496,22 +496,22 @@ namespace aspect
496496
compute_gravity_heating(const double Tc, const double r, const double X) const;
497497

498498
/**
499-
* Calculate entropy (@p Ek) and energy (@p Qk) change rate factor
499+
* Calculate energy (@p Qk) and entropy (@p Ek) change rate factor
500500
* (regarding the core cooling rate Tc/dt) for a given @p Tc (CMB temperature)
501501
*
502-
* @return A pair of (Ek, Qk), i.e., the entropy change rate factor first
503-
* and the energy change rate factor second.
502+
* @return A pair of (Qk, Ek), i.e., the energy change rate factor first
503+
* and the entropy change rate factor second.
504504
*/
505505
std::pair<double,double>
506506
compute_adiabatic_heating(const double Tc) const;
507507

508508
/**
509-
* Calculate entropy (@p El) and energy (@p Ql) change rate factor
509+
* Calculate energy (@p Ql) and entropy (@p El) change rate factor
510510
* (regarding the inner core growth rate dR/dt) for a given @p Tc (CMB temperature)
511511
* and @p r (inner core radius)
512512
*
513-
* @return A pair of (El, Ql), i.e., the entropy change rate factor first
514-
* and the energy change rate factor second.
513+
* @return A pair of (Ql, El), i.e., the energy change rate factor first
514+
* and the entropy change rate factor second.
515515
*/
516516
std::pair<double,double>
517517
compute_latent_heating(const double Tc, const double r) const;

source/boundary_temperature/dynamic_core.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -515,8 +515,8 @@ namespace aspect
515515
std::tie(core_data.Qs,core_data.Es) = compute_specific_heating(core_data.Ti);
516516
std::tie(core_data.Qr,core_data.Er) = compute_radio_heating(core_data.Ti);
517517
std::tie(core_data.Qg,core_data.Eg) = compute_gravity_heating(core_data.Ti,core_data.Ri,core_data.Xi);
518-
std::tie(core_data.Ek,core_data.Qk) = compute_adiabatic_heating(core_data.Ti);
519-
std::tie(core_data.El,core_data.Ql) = compute_latent_heating(core_data.Ti,core_data.Ri);
518+
std::tie(core_data.Qk,core_data.Ek) = compute_adiabatic_heating(core_data.Ti);
519+
std::tie(core_data.Ql,core_data.El) = compute_latent_heating(core_data.Ti,core_data.Ri);
520520
core_data.Eh = compute_heat_solution(core_data.Ti,core_data.Ri,core_data.Xi);
521521
}
522522

@@ -811,7 +811,7 @@ namespace aspect
811811

812812
const double Ek = 16*numbers::PI*k_c*Utilities::fixed_power<5>(Rc)/5/Utilities::fixed_power<4>(D);
813813
const double Qk = 8*numbers::PI*Utilities::fixed_power<3>(Rc)*k_c*Tc/Utilities::fixed_power<2>(D);
814-
return { Ek, Qk };
814+
return { Qk, Ek };
815815
}
816816

817817

@@ -830,7 +830,7 @@ namespace aspect
830830

831831
const double Ql = 4.*numbers::PI*Utilities::fixed_power<2>(r)*Lh*compute_rho(r);
832832
const double El = Ql*(compute_T(Tc,r)-Tc)/(Tc*compute_T(Tc,r));
833-
return { El, Ql };
833+
return { Ql, El };
834834
}
835835

836836

0 commit comments

Comments
 (0)