Skip to main content

streamr

Function streamr 

Source
pub fn streamr(
    q: f64,
    rad: f64,
    n_points: usize,
) -> Result<(Vec<f64>, Vec<f64>), RocheError>
Expand description

streamr works by integrating the equations of motion for the Roche potential using Burlisch-Stoer integration. It stops when the stream reaches a target radius or a minimum radius, whichever is the larger.

Arguments:

  • q: mass ratio = M2/M1. Stream flows from star 2 to 1.
  • rad: Radius to aim for. If this is less than the minimum, the stream will stop at the minimum
  • n_points: number of points to compute.

Results:

  • x: array of x values returned.
  • y: array of y values returned.