pub fn observed_frequency_longitudinal(
emitted_frequency: f64,
beta: f64,
) -> Option<f64>Expand description
Computes observed longitudinal Doppler-shifted frequency f_observed = f_emitted * D.
Positive beta means the source is approaching the observer.
Returns None when emitted_frequency is negative or not finite, when beta is invalid, or
when the computed frequency is not finite.
ยงExamples
use use_relativity::observed_frequency_longitudinal;
assert!((observed_frequency_longitudinal(100.0, 0.6).unwrap() - 200.0).abs() < 1.0e-12);