Read a star's bolometric correction off its colour, and carry Gaia's G to V first

A star's luminosity was its absolute magnitude plus a bolometric correction read off its spectral
type, with its magnitude taken as V whatever band it was in. Gaia classifies none of its stars, so
all of its 379 000 got the Sun's correction, and their G was read as V: TRAPPIST-1 came out at a
seventh of its luminosity.

The dwarf sequence spectral.ts already reads types off (Pecaut & Mamajek 2013, table 5, online
version 2022.04.16) now carries its effective temperature, bolometric correction to V and Gaia
G-V columns, and dwarfSequenceAtColor interpolates them at a colour, in the colour's own system.
luminositySolar uses it wherever the star's colour is inside the table: the G magnitude is
carried to V, then corrected. Only without such a colour does it fall back to the spectral type,
as before.

Against the archive's own st_lum for the 1 449 hosts that are catalogue stars, the median error
goes from 0.038 to 0.022 dex and the 90th percentile from 0.292 to 0.115 dex; within a factor of
1.5, 84.5 % -> 93.8 %. For the 572 hosts Gaia describes: 90th percentile 0.332 -> 0.073 dex,
81.8 % -> 97.0 % within a factor of 1.5. Barnard's Star with no type now reads 0.0029 L_sun
against 0.0035 published, and TRAPPIST-1 7.3e-4 against 5.5e-4 (Agol et al. 2021).

Across the catalogue, 311 255 of 455 608 stars move by more than 10 % (median ratio 0.90: a
G-type star's G is 0.16 brighter than its V), and so do the hosts of 3 158 planets, whose
equilibrium temperatures follow as the fourth root.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-09-25 00:02:12 +02:00
co-authored by Claude Opus 5.5
parent 81a4ecfcde
commit 3392f06c85
5 changed files with 128 additions and 30 deletions
+26 -1
View File
@@ -1,6 +1,6 @@
import { describe, expect, it } from 'vitest';
import { parseSpectralClass, SPECTRAL_CLASSES, spectralTypeFromColor, spectralTypeToColorIndex, temperatureToColorIndex } from './spectral';
import { dwarfSequenceAtColor, parseSpectralClass, SPECTRAL_CLASSES, spectralTypeFromColor, spectralTypeToColorIndex, temperatureToColorIndex } from './spectral';
describe('parseSpectralClass', () => {
it('reads a clean class and subclass', () => {
@@ -128,3 +128,28 @@ describe('spectralTypeFromColor', () => {
expect(spectralTypeFromColor(-0.301, 'B-V')).toBe('B0');
});
});
describe('dwarfSequenceAtColor', () => {
it("puts the Sun's colour in either system at the Sun's temperature and correction", () => {
for (const [colour, system] of [[0.65, 'B-V'], [0.823, 'BP-RP']] as const) {
const point = dwarfSequenceAtColor(colour, system)!;
expect(point.temperatureK).toBeCloseTo(5770, 0);
expect(point.bolometricCorrectionV).toBeCloseTo(-0.085, 3);
expect(point.gMinusV).toBeCloseTo(-0.165, 3);
}
});
it('interpolates between the two types a colour falls between', () => {
// Halfway from M1.5 (B−V 1.495, 3 620 K, −1.50) to M2 (1.505, 3 560 K, −1.62).
const point = dwarfSequenceAtColor(1.5, 'B-V')!;
expect(point.temperatureK).toBeCloseTo(3590, 6);
expect(point.bolometricCorrectionV).toBeCloseTo(-1.56, 6);
});
it('has no answer past either end of the table, and no G−V where none is tabulated', () => {
expect(dwarfSequenceAtColor(2.2, 'B-V')).toBeNull();
expect(dwarfSequenceAtColor(-0.15, 'BP-RP')).toBeNull();
expect(dwarfSequenceAtColor(null)).toBeNull();
expect(dwarfSequenceAtColor(-0.29, 'B-V')!.gMinusV).toBeNull();
});
});