The test suite that ensures the correct locks are selected for monitoring and the fixes applied to the tidal frequency are correct. More...
#include <testLockMonitoring.h>
Public Member Functions | |
test_LockMonitoring () | |
Create the test suite. More... | |
void | test_lock_init () |
Test whether the correct tidal terms are selected for lock monitoring when \(\Omega_spin>0\) and. More... | |
void | test_tidal_frequency_fix () |
Test fix applied to the tidal frequency of tidal term(s) matching lower boundary lock. More... | |
Protected Member Functions | |
void | setup () |
No fixture at this point. More... | |
void | tear_down () |
No fixture at this point. More... | |
Private Member Functions | |
void | set_expansion_order (int max_orbital_multiplier) |
Change the order of the tidal potential expansion used by __zone. More... | |
void | set_orbital_spin_frequeqncy (double orbital_frequency, double spin_frequency) |
Change the orbital and spin frequencies for __zone. More... | |
void | add_locks_to_message (const SpinOrbitLockInfo &lock_below, const SpinOrbitLockInfo &lock_above, std::ostringstream &message) |
Add information about the given locks relative to the tidal frequency to the test message. More... | |
void | add_zone_locks_to_message (std::ostringstream &message) |
void | check_monitored_locks (double orbital_frequency, double spin_frequency, const SpinOrbitLockInfo &expected_lock_below, const SpinOrbitLockInfo &expected_lock_above) |
Verify a single expectation of what locks would be monitored in a given situation. More... | |
double | sample_range (std::pair< double, double > range, unsigned position) |
Pick a just inside each boundary or in the middle of a range. More... | |
void | check_tidal_frequency_range (double lock_set_orbital_frequency, double lock_set_spin_frequency, double test_orbital_frequency, std::pair< double, double > test_spin_frequency_range, int orbital_frequency_multiplier, int spin_frequency_multiplier, int expected_correction) |
Verify a single expectation for fixing of a tidal term in a given situation over a range of spin frequencies. More... | |
void | check_unlocked_tidal_frequency (int expansion_order, int lower_lock_orbital_freuqency_multiplier, double orbital_frequency) |
Check that lock-corrected tidal frequency reproduces expectations for a single set of monitored locks. More... | |
Private Attributes | |
Planet::PlanetZone | __zone |
A dissipative zone to run the tests on. More... | |
The test suite that ensures the correct locks are selected for monitoring and the fixes applied to the tidal frequency are correct.
Definition at line 25 of file testLockMonitoring.h.
Evolve::test_LockMonitoring::test_LockMonitoring | ( | ) |
Create the test suite.
Definition at line 319 of file testLockMonitoring.cpp.
|
private |
Add information about the given locks relative to the tidal frequency to the test message.
Definition at line 37 of file testLockMonitoring.cpp.
|
private |
Add the locks currently selected for monitoring in __zone to the message.
Definition at line 54 of file testLockMonitoring.cpp.
|
private |
Verify a single expectation of what locks would be monitored in a given situation.
Definition at line 71 of file testLockMonitoring.cpp.
|
private |
Verify a single expectation for fixing of a tidal term in a given situation over a range of spin frequencies.
lock_set_orbital_frequency | The orbital frequency to use when setting the locks of a zone. |
lock_set_spin_frequency | The spin frequency to use when setting locks of a zone. |
test_orbital_frequency | The orbital frequency at which to calculate the possibly corrected tidal frequency. |
test_spin_frequency_range | The range of spin frequencies at which to calculate the possibly corrected tidal frequency. Comparison is done near each end of the range and the middle. |
orbital_frequency_multiplier | The multiplier in front of the orbital frequency of the tidal |
spin_frequency_multiplier | The multiplier in front of the spin frequency of the tidal |
expected_correction | 1 if the tidal frequency should be corrected to positive 0 if the tidal frequency should not be corrected -1 if the tidal frequency should be corrected to negative |
Definition at line 159 of file testLockMonitoring.cpp.
|
private |
Check that lock-corrected tidal frequency reproduces expectations for a single set of monitored locks.
expansion_order | The largest orbital frequency multiplier to include in the expansion. |
lower_lock_orbital_freuqency_multiplier | The orbital frequency multiplier of the tidal term defining the lower limit on the spin frequency to watch, assimung the spin frequency multiplier is 2. |
orbital_frequency | All tests are performed at this fixed orbital frequency. |
Definition at line 245 of file testLockMonitoring.cpp.
|
private |
Pick a just inside each boundary or in the middle of a range.
range | The range to sample. |
position | If 0 pick the smallest float above the range min If 1 pick the middle of the range If 2 pick the largest float below range max |
Definition at line 135 of file testLockMonitoring.cpp.
|
private |
Change the order of the tidal potential expansion used by __zone.
Definition at line 14 of file testLockMonitoring.cpp.
|
private |
Change the orbital and spin frequencies for __zone.
Definition at line 21 of file testLockMonitoring.cpp.
|
inlineprotected |
No fixture at this point.
Definition at line 118 of file testLockMonitoring.h.
|
inlineprotected |
No fixture at this point.
Definition at line 121 of file testLockMonitoring.h.
void Evolve::test_LockMonitoring::test_lock_init | ( | ) |
Test whether the correct tidal terms are selected for lock monitoring when \(\Omega_spin>0\) and.
Definition at line 336 of file testLockMonitoring.cpp.
void Evolve::test_LockMonitoring::test_tidal_frequency_fix | ( | ) |
Test fix applied to the tidal frequency of tidal term(s) matching lower boundary lock.
Definition at line 391 of file testLockMonitoring.cpp.
|
private |
A dissipative zone to run the tests on.
Definition at line 28 of file testLockMonitoring.h.