API Reference / pheno · function
Function: pheno()
function pheno(
engine,
body,
jdUt): Pheno;
Photometric and apparent-geometry quantities for a body at an instant: its phase angle, illuminated fraction, elongation from the Sun, apparent disc diameter, and apparent visual magnitude.
Parameters
| Parameter | Type | Description |
|---|---|---|
engine | Engine | The engine used to evaluate positions. |
body | BodyId | A body with known physical dimensions (Sun, Moon, the planets). |
jdUt | number | Julian Day (UT). |
Returns
A Pheno: phaseAngle (deg), phase (lit fraction 0–1),
elongation (deg), diameter (deg), and magnitude.
Throws
Error if body has no photometric data.
Example
pheno(engine, "venus", julianDay(2025, 6, 1)).phase; // illuminated fraction