Planetary Orbital Evolution due to Tides
Orbital evolution of two objects experiencing tides
Evolve::test_LockMonitoring Class Reference

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>

+ Inheritance diagram for Evolve::test_LockMonitoring:
+ Collaboration diagram for Evolve::test_LockMonitoring:

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...
 

Detailed Description

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.

Constructor & Destructor Documentation

◆ test_LockMonitoring()

Evolve::test_LockMonitoring::test_LockMonitoring ( )

Create the test suite.

Definition at line 319 of file testLockMonitoring.cpp.

Member Function Documentation

◆ add_locks_to_message()

void Evolve::test_LockMonitoring::add_locks_to_message ( const SpinOrbitLockInfo lock_below,
const SpinOrbitLockInfo lock_above,
std::ostringstream &  message 
)
private

Add information about the given locks relative to the tidal frequency to the test message.

Definition at line 37 of file testLockMonitoring.cpp.

◆ add_zone_locks_to_message()

void Evolve::test_LockMonitoring::add_zone_locks_to_message ( std::ostringstream &  message)
private

Add the locks currently selected for monitoring in __zone to the message.

Definition at line 54 of file testLockMonitoring.cpp.

◆ check_monitored_locks()

void Evolve::test_LockMonitoring::check_monitored_locks ( double  orbital_frequency,
double  spin_frequency,
const SpinOrbitLockInfo expected_lock_below,
const SpinOrbitLockInfo expected_lock_above 
)
private

Verify a single expectation of what locks would be monitored in a given situation.

Definition at line 71 of file testLockMonitoring.cpp.

◆ check_tidal_frequency_range()

void Evolve::test_LockMonitoring::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 
)
private

Verify a single expectation for fixing of a tidal term in a given situation over a range of spin frequencies.

Parameters
lock_set_orbital_frequencyThe orbital frequency to use when setting the locks of a zone.
lock_set_spin_frequencyThe spin frequency to use when setting locks of a zone.
test_orbital_frequencyThe orbital frequency at which to calculate the possibly corrected tidal frequency.
test_spin_frequency_rangeThe 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_multiplierThe multiplier in front of the orbital frequency of the tidal
spin_frequency_multiplierThe multiplier in front of the spin frequency of the tidal
expected_correction1 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.

◆ check_unlocked_tidal_frequency()

void Evolve::test_LockMonitoring::check_unlocked_tidal_frequency ( int  expansion_order,
int  lower_lock_orbital_freuqency_multiplier,
double  orbital_frequency 
)
private

Check that lock-corrected tidal frequency reproduces expectations for a single set of monitored locks.

Parameters
expansion_orderThe largest orbital frequency multiplier to include in the expansion.
lower_lock_orbital_freuqency_multiplierThe 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_frequencyAll tests are performed at this fixed orbital frequency.

Definition at line 245 of file testLockMonitoring.cpp.

◆ sample_range()

double Evolve::test_LockMonitoring::sample_range ( std::pair< double, double >  range,
unsigned  position 
)
private

Pick a just inside each boundary or in the middle of a range.

Parameters
rangeThe range to sample.
positionIf 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.

◆ set_expansion_order()

void Evolve::test_LockMonitoring::set_expansion_order ( int  max_orbital_multiplier)
private

Change the order of the tidal potential expansion used by __zone.

Definition at line 14 of file testLockMonitoring.cpp.

◆ set_orbital_spin_frequeqncy()

void Evolve::test_LockMonitoring::set_orbital_spin_frequeqncy ( double  orbital_frequency,
double  spin_frequency 
)
private

Change the orbital and spin frequencies for __zone.

Definition at line 21 of file testLockMonitoring.cpp.

◆ setup()

void Evolve::test_LockMonitoring::setup ( )
inlineprotected

No fixture at this point.

Definition at line 118 of file testLockMonitoring.h.

◆ tear_down()

void Evolve::test_LockMonitoring::tear_down ( )
inlineprotected

No fixture at this point.

Definition at line 121 of file testLockMonitoring.h.

◆ test_lock_init()

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.

◆ test_tidal_frequency_fix()

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.

Member Data Documentation

◆ __zone

Planet::PlanetZone Evolve::test_LockMonitoring::__zone
private

A dissipative zone to run the tests on.

Definition at line 28 of file testLockMonitoring.h.


The documentation for this class was generated from the following files: