For the complete documentation index, see llms.txt. This page is also available as Markdown.

Math and Physics

Math and physics helpers provide small, reliable building blocks for add-ons that need to calculate, compare, or visualize derived values.

These functions are not tied to a specific telemetry object. They work from values you provide, such as angles, vectors, distances, altitude, speed, or gravity.

Use this section when your add-on needs to answer practical questions such as:

  • How do I normalize or compare angles safely?

  • How do I calculate a derived physical value?

  • How do I avoid rewriting common math formulas in every add-on?

  • How do I keep analysis code readable and consistent with Tacview?

Why use these helpers?

Many analysis tools start from telemetry values, then derive something more useful from them.

For example, an add-on may read an aircraft altitude and speed from telemetry, then calculate its specific energy height. Another add-on may later use angle, vector, or unit helpers to keep geometry and export code simple.

Keeping these calculations in common helpers has several advantages:

  • add-ons stay easier to read;

  • formulas are implemented consistently;

  • units and conventions are documented in one place;

  • future improvements benefit all add-ons using the helper.

Physical calculations

Use physical calculation helpers when you want to derive analysis values from telemetry data.

Specific energy height is useful for comparing aircraft energy states. It combines altitude and speed into one value expressed as an equivalent altitude.

Units and conventions

Unless stated otherwise, math and physics helpers use Tacview's internal units:

  • distances and altitudes are in meters;

  • speeds are in meters per second;

  • angles are in radians;

  • gravity is in meters per second squared.

Keep these units for calculations. Convert or format values only when displaying them to the user or exporting text.

Relationship with other sections

Use Object Data to read values from telemetry objects, such as transforms, speeds, airspeeds, Mach number, or pressure altitude.

Use Geometry and Coordinates for spatial calculations based on Tacview transforms, simulator coordinates, or world coordinates.

Use this section for generic calculations that do not need to know where a value came from.

Last updated