How mjohne/planetoid-db works
Purpose and Runtime
Planetoid-DB is a desktop viewer and analysis tool for the Minor Planet Center’s large fixed-format MPCORB.DAT orbital catalog. It is a C# Windows Forms application, built from Planetoid-DB.csproj, launched through Program.cs, with application settings in Properties/Settings.settings.
Application Shell and Navigation
The main workspace is Forms/PlanetoidDBForm.cs, split by responsibility across Forms/PlanetoidDBForm.EventHandlers.cs, Forms/PlanetoidDBForm.Decoders.cs, and Forms/PlanetoidDBForm.DatabaseUpdates.cs. It owns user-driven control flow: loading/reloading catalog data, decoding records, selection, and launching specialized analysis or display forms. Startup presentation is separated into Forms/SplashScreenForm.cs and Forms/PreloadForm.cs.
Catalog Ingestion and Record Boundary
The core external-data boundary is the MPCORB ASCII file, downloaded or selected by the user and parsed into an internal record model at Helpers/PlanetoidRecord.cs. UI acquisition/update paths are represented by Forms/DatabaseDownloaderForm.cs, Forms/ArchiveMpcorbForm.cs, and main-form database update logic. Parsing/decoding is centralized at the main form rather than a separate persistence or server layer; the application is a local file reader, not a database-backed service.
Search, Filtering, and Tabular Exploration
Loaded records feed interactive filtering, searching, sorting, and table-mode presentation. Key surfaces are Forms/FilterForm.cs, Forms/SearchForm.cs, and Forms/TableModeForm.cs. Records can be inspected through Forms/RecordsForm.cs and compared through Forms/DatabaseDifferencesForm.cs. This is the principal user flow: catalog file → decoded PlanetoidRecord collection → filtered/selected records → detail, export, or analysis action.
Orbital Computation Layer
Domain calculations are factored into reusable helper classes, operating on selected records and producing derived values for the UI. Helpers/DerivedElements.cs calculates orbital derivatives; Helpers/MoidCalculator.cs and Helpers/MaxoidCalculator.cs support minimum/maximum orbital-intersection-distance analyses; Helpers/TisserandParameterCalculator.cs computes Tisserand parameters. Their results are surfaced through focused forms such as Forms/DerivedOrbitElementsForm.cs, Forms/MoidsOfAllMinorPlanetsForm.cs, and Forms/TisserandParameterOfAllMinorPlanetsForm.cs.
Visualization and Analytical Workflows
The application offers dedicated WinForms workflows for plotting and astronomical exploration rather than a generic reporting engine. Orbit rendering is handled by Forms/Orbit2DTopViewForm.cs, Forms/Orbit2DSideViewForm.cs, and Forms/Orbit3DForm.cs; aggregate visualization uses Forms/HistogramsForm.cs and Forms/ScatterplotsForm.cs. Additional workflows include family/resonance analysis and ephemeris lookup via Forms/AsteroidFamiliesForm.cs, Forms/OrbitalResonancesOfAllMinorPlanetsForm.cs, and Forms/EphemerisForm.cs.
Import/Export, Resources, and External Sources
The app can download bulk observation data through Forms/BulkObservationsDataDownloaderForm.cs and export selected/tabular data via Forms/ExportDataSheetForm.cs plus Helpers/ListViewExporter.cs. Embedded resources provide observatory codes and terminology documentation (Resources/ObservatoryCodes.txt, Resources/TerminologyDocs/). The material external service/data authority is the Minor Planet Center, supplying MPCORB and related astronomical datasets; archived catalog references are published as static documentation under docs/.
Main entry points: PlanetoidDBForm.cs Main workspace · PlanetoidRecord.cs Planetoid record · Program.cs Application entry · FilterForm.cs Search, filter & table
Components 20
Desktop shell
- WinForms project
Planetoid-DB.csproj - Application entry
Program.cs - Application settings
Properties/Settings.settings - Splash & preload
Forms/SplashScreenForm.cs - Main workspace · Owns catalog state, selection, and workflow navigation.
Forms/PlanetoidDBForm.cs
Catalog workflow
- Record decoders
Forms/PlanetoidDBForm.Decoders.cs - Catalog updates
Forms/PlanetoidDBForm.DatabaseUpdates.cs - Catalog acquisition
Forms/DatabaseDownloaderForm.cs - Planetoid record
Helpers/PlanetoidRecord.cs - Search, filter & table
Forms/FilterForm.cs - Record inspection & diff
Forms/RecordsForm.cs
Analysis & visualization
- Orbital calculators · Derived elements, MOID/MAXOID, and Tisserand calculations.
Helpers/DerivedElements.cs - Derived orbital analysis
Forms/DerivedOrbitElementsForm.cs - 2D & 3D orbit views
Forms/Orbit2DTopViewForm.cs - Histograms & scatterplots
Forms/HistogramsForm.cs - Families, resonances & ephemeris
Forms/AsteroidFamiliesForm.cs
Data sources & export
- MPCORB catalog · Fixed-format orbital catalog from the Minor Planet Center.
- Observation data download
Forms/BulkObservationsDataDownloaderForm.cs - Data export
Forms/ExportDataSheetForm.cs - MPC resources · Observatory codes and terminology documentation.
Resources/ObservatoryCodes.txt
Connections 22
- WinForms project → Application entry: builds
- Application entry → Splash & preload: shows
- Application entry → Main workspace: launches
- Application settings → Main workspace: configures
- Splash & preload → Main workspace: continues to
- Main workspace → Record decoders: uses
- Main workspace → Catalog updates: uses
- Catalog updates → Catalog acquisition: opens
- Catalog acquisition → MPCORB catalog: downloads or selects
- MPCORB catalog → Record decoders: fixed-format input
- Record decoders → Planetoid record: parses into
- Planetoid record → Main workspace: loaded collection
- Main workspace → Search, filter & table: opens
- Search, filter & table → Record inspection & diff: selected records
- Search, filter & table → Data export: selected/tabular data
- Main workspace → Orbital calculators: selected records
- Orbital calculators → Derived orbital analysis: derived results
- Planetoid record → 2D & 3D orbit views: orbital elements
- Planetoid record → Histograms & scatterplots: catalog data
- Planetoid record → Families, resonances & ephemeris: analysis input
- Observation data download → MPCORB catalog: related MPC datasets
- MPC resources → Main workspace: reference data