Skip to Content

orbitforge od bls

Synopsis

orbitforge od bls --obs <PATH> --stations <PATH> --initial <PATH> --epoch <RFC3339> [OPTIONS]

Description

Batch least squares estimates one state at one epoch using all observations in the arc at once. It iterates: propagate from the current estimate, compute the residual against every measurement, solve for the correction that minimizes the weighted sum of squares, apply it, repeat.

This is the classic orbit determination method, and it is the right choice when you have a complete arc and want the best single answer with a covariance.

Options

ParameterTypeUnitDefaultRequiredDescription
--obspathn/a—YesTracking CSV, as produced by `od simulate-tracking --csv`.
--stationspathn/a—YesTracking-stations JSON. Must describe every station appearing in the observation file.
--initialpathn/a—YesKeplerian-elements JSON, the initial guess at the solution epoch.
--epochstringRFC 3339 UTC—YesSolution epoch. Observations must not precede it.
--forceenumn/aj2NoReference force model: `two-body`, `j2`, or `j4`.
--edit-sigmafloatsigma4NoResidual editing threshold. Observations beyond this many sigma are excluded. Zero disables editing.
--max-iterationsintegercount10NoIteration cap. Reaching it without convergence is a failure, not an answer.
--jsonpathn/a—NoWrite the full solution: state, covariance, and per-observation residuals.

Worked example

Fitting the 220 observations generated by od simulate-tracking:

orbitforge od bls \ --obs obs.csv \ --stations stations.json \ --initial orbit.json \ --epoch 2026-01-01T00:00:00Z
BLS converged in 3 iterations: RMS 1.030, 220 used / 0 edited. Position sigma [0.0006, 0.0008, 0.0009] km; velocity sigma [6.12e-7, 9.65e-7, 9.25e-7] km/s.

Reading the output

FigureValueMeaning
Iterations3How many corrections were needed. Fewer is better; hitting the cap means it did not converge
RMS1.030Weighted root-mean-square residual, dimensionless
Used / edited220 / 0Observations accepted, and rejected by residual editing
Position sigmasub-meter, per axisFormal uncertainty in the estimated position at the epoch
Velocity sigmasub-mm/s, per axisFormal uncertainty in velocity

An RMS near 1.0 is the target, and 1.030 is close to ideal. The residuals are weighted by each observation’s sigma, so an RMS of 1 means the fit disagrees with the data by about as much as the stated measurement noise, which is exactly right.

Much above 1 means the model cannot explain the data: wrong force model, a station in the wrong place, or an epoch mismatch. Much below 1 means the stated sigmas are pessimistic, and the covariance is then too conservative to be useful.

Zero edited observations is consistent with synthetic data at the same noise level the solver assumes. Against real tracking, some editing is normal.

Residual editing

--edit-sigma excludes observations whose residuals exceed the threshold, which protects the solution from outliers: an epoch tagged wrongly or a transcription error can otherwise drag the entire fit.

It is also a way to hide a real problem. If editing removes a substantial fraction of the arc, the correct response is to find out why those observations disagree, not to raise the threshold until they vanish. Setting --edit-sigma 0 disables editing and shows the unfiltered fit, which is worth doing once when diagnosing.

Covariance is formal, not truth

The reported sigmas are the formal covariance from the fit: what the estimator believes given its own model and the stated measurement noise. They are optimistic whenever the force model is incomplete, because unmodeled acceleration appears as signal the estimator confidently absorbs.

A sub-meter formal sigma from a J2-only fit does not mean the orbit is known to sub-meter accuracy. It means the fit is internally consistent to sub-meter level.

Batch or filter

Use batch least squares whenUse od ekf when
The whole arc is availableObservations arrive over time
You want one best epoch stateYou want a current state that updates
You want a covariance for that epochYou need to track a maneuvering or evolving object
Post-processingNear real time

Batch uses every observation to constrain one epoch, so it smooths over the whole arc. The filter propagates forward and never revisits an earlier measurement. That difference shows up directly in the reported uncertainty: compare these sigmas against the EKF’s on the same data.

See also

Question? Give us feedbackDocuments Varaha Constellation Designer main (pre-release)
Last updated on