Skip to content

Documentation / @interstellar-tools/maps / swathWidth

Function: swathWidth() ​

ts
function swathWidth(distance: number, fieldOfView: Radians): number;

Defined in: imaging/swath-width.ts:59

Compute the swath width: the strip of ground a camera covers across its track, looking straight down.

w=2Htan⁡θ2≈HIFOVN

Where:

  • H is the distance to the ground (m)
  • θ is the camera's field of view across track (rad), about the IFOV times the number of pixels N across

Units

  • Inputs: distance in m, fieldOfView in radians.
  • Output: w in m.

Notes

  • Flat ground seen straight down. Over a curved body the edges are a little further away, and a wide field of view on a low orbit can reach past the horizon (see horizonDistance in @interstellar-tools/equations).
  • With the orbit's ground speed it sets how fast a camera maps: the area per second is the swath times the speed.
In practiceHiRISE, over Mars

5.97 km

HiRISE's 1.14° field of view across track, from 300 km

NASA quotes the swath as 6 km. At 30 cm a pixel, that's about 20 000 pixels across.

ts
swathWidth(300_000, toRad(1.14)); // ≈ 5 969 m

Parameters ​

ParameterTypeDescription
distancenumberDistance H to the ground in m (finite, > 0).
fieldOfViewRadiansField of view θ across track in radians (finite, > 0, < π).

Returns ​

number

The swath width w in m.

Throws ​

  • If any input is not a finite number.
  • If distance <= 0, or fieldOfView is outside (0, π).

Example ​

ts
import type { Radians } from '@interstellar-tools/types';

// A 90° field of view sees twice its height across
swathWidth(1000, (Math.PI / 2) as Radians); // 2 000 m

See ​