stellar function

({double deltaD, double t}) stellar(
  1. double t1,
  2. double t5,
  3. Equatorial c1,
  4. List<Equatorial> cs2,
)

Computes a conjunction between a moving object and a fixed star.

c1 is the fixed object, cs2 is the 5-row ephemeris of the mover.

Implementation

({double t, double deltaD}) stellar(
    double t1, double t5, Equatorial c1, List<Equatorial> cs2) {
  if (cs2.length != 5) {
    throw ArgumentError('Five rows required in ephemerides');
  }
  final dr = List<double>.generate(5, (i) => cs2[i].ra - c1.ra);
  final dd = List<double>.generate(5, (i) => cs2[i].dec - c1.dec);
  return _conj(t1, t5, dr, dd);
}