# sgl-ut/gnsstk architecture

> Architecture diagram of the GitHub repository sgl-ut/gnsstk, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-17). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sgl-ut/gnsstk
- Repository: https://github.com/sgl-ut/gnsstk

## Overview

GNSSTk is a C++ GNSS library and applications foundation. A typical user workflow supplies GNSS observations and navigation data, uses time, satellite, ephemeris, and atmospheric models to process them, and obtains a position solution; the README also identifies PPP processing and integrity monitoring. The map preserves major library capabilities and supporting data-format, math, and framework layers. Relationships are documented capability-level links from the README, not verified runtime call paths; unsampled implementation details are intentionally not inferred.

Main entry points: [`core/lib/ClockModel/ObsEpochMap.hpp`](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/ClockModel/ObsEpochMap.hpp) (Observation Data), [`core/lib/NewNav/MultiFormatNavDataFactory.cpp`](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/NewNav/MultiFormatNavDataFactory.cpp) (Navigation Data), [`core/lib/PosSol/PRSolution2.cpp`](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/PosSol/PRSolution2.cpp) (Position Solution), [`core/lib/FileHandling`](https://github.com/sgl-ut/gnsstk/tree/stable/core/lib/FileHandling) (GNSS Formats)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["GNSS Data"]
  node_formats["GNSS Formats"]
  node_observations["Observation Data<br/>[ObsEpochMap.hpp]"]
  node_navdata["Navigation Data"]
  node_navfilters["Navigation Filters<br/>[NavFilterMgr.hpp]"]
end

subgraph group_models["Navigation Models"]
  node_ephemeris["Ephemeris Models<br/>[EngEphemeris.cpp]"]
  node_atmosphere["Atmospheric Models<br/>[IonoModel.hpp]"]
  node_geomatics["Geodetic Models"]
  node_corrections["Signal Corrections<br/>[GroupPathCorr.cpp]"]
end

subgraph group_solutions["Positioning"]
  node_pseudorange["Pseudorange Ranging<br/>[RawRange.cpp]"]
  node_position["Position Solution<br/>[PRSolution2.cpp]"]
  node_ppp["PPP Processing"]
  node_integrity["Integrity Monitoring<br/>[PRSolution2.cpp]"]
end

subgraph group_foundation["Core Foundation"]
  node_time["Time Handling<br/>[CommonTime.hpp]"]
  node_satellite["Satellite Geometry<br/>[SatID.hpp]"]
  node_math["Math Toolkit<br/>[Matrix.hpp]"]
  node_coordinates["Coordinates<br/>[Position.hpp]"]
  node_framework["Application Framework<br/>[BasicFramework.hpp]"]
  node_cli["Command Options"]
  node_utilities["Utilities<br/>[StringUtils.hpp]"]
end

node_user(("GNSS User"))

node_user -->|"supplies data"| node_formats
node_formats -->|"provides observations"| node_observations
node_formats -->|"provides navigation"| node_navdata
node_navdata -.->|"supports processing"| node_navfilters
node_observations -.->|"uses time"| node_time
node_navdata -->|"supports calculations"| node_ephemeris
node_observations -.->|"supports ranging"| node_pseudorange
node_ephemeris -->|"enables ranging"| node_pseudorange
node_pseudorange -->|"supports solution"| node_position
node_atmosphere -->|"models refraction"| node_position
node_geomatics -.->|"supports processing"| node_ppp
node_observations -->|"processed by"| node_ppp
node_navdata -.->|"processed by"| node_ppp
node_position -->|"includes integrity"| node_integrity
node_time -.->|"supports conversions"| node_coordinates
node_satellite -.->|"identifies satellites"| node_ephemeris
node_math -->|"supports algorithms"| node_position
node_user -->|"uses applications"| node_framework
node_framework -.->|"processes options"| node_cli
node_corrections -.->|"models delays"| node_atmosphere

click node_formats "https://github.com/sgl-ut/gnsstk/tree/stable/core/lib/FileHandling"
click node_observations "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/ClockModel/ObsEpochMap.hpp"
click node_navdata "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/NewNav/MultiFormatNavDataFactory.cpp"
click node_navfilters "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/NavFilter/NavFilterMgr.hpp"
click node_time "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/TimeHandling/CommonTime.hpp"
click node_satellite "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/SatID.hpp"
click node_ephemeris "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSEph/EngEphemeris.cpp"
click node_atmosphere "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/IonoModel.hpp"
click node_geomatics "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Geomatics/EarthOrientation.hpp"
click node_corrections "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/GroupPathCorr.cpp"
click node_pseudorange "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSEph/RawRange.cpp"
click node_position "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/PosSol/PRSolution2.cpp"
click node_ppp "https://github.com/sgl-ut/gnsstk/tree/stable/core/lib/Geomatics"
click node_integrity "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/PosSol/PRSolution2.cpp"
click node_math "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Math/Matrix/Matrix.hpp"
click node_coordinates "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/Position.hpp"
click node_framework "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/AppFrame/BasicFramework.hpp"
click node_cli "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/CommandLine/CommandOptionParser.cpp"
click node_utilities "https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Utilities/StringUtils.hpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_formats,node_observations,node_navdata,node_navfilters,node_user toneBlue
class node_ephemeris,node_atmosphere,node_geomatics,node_corrections toneAmber
class node_pseudorange,node_position,node_ppp,node_integrity toneMint
class node_time,node_satellite,node_math,node_coordinates,node_framework,node_cli,node_utilities toneRose
```

## Components

### GNSS Data

- [GNSS Formats](https://github.com/sgl-ut/gnsstk/tree/stable/core/lib/FileHandling): `core/lib/FileHandling`
- [Observation Data](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/ClockModel/ObsEpochMap.hpp): `core/lib/ClockModel/ObsEpochMap.hpp`
- [Navigation Data](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/NewNav/MultiFormatNavDataFactory.cpp): `core/lib/NewNav/MultiFormatNavDataFactory.cpp`
- [Navigation Filters](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/NavFilter/NavFilterMgr.hpp): `core/lib/NavFilter/NavFilterMgr.hpp`

### Navigation Models

- [Ephemeris Models](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSEph/EngEphemeris.cpp): `core/lib/GNSSEph/EngEphemeris.cpp`
- [Atmospheric Models](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/IonoModel.hpp): `core/lib/GNSSCore/IonoModel.hpp`
- [Geodetic Models](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Geomatics/EarthOrientation.hpp): `core/lib/Geomatics/EarthOrientation.hpp`
- [Signal Corrections](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/GroupPathCorr.cpp): `core/lib/GNSSCore/GroupPathCorr.cpp`

### Positioning

- [Pseudorange Ranging](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSEph/RawRange.cpp): `core/lib/GNSSEph/RawRange.cpp`
- [Position Solution](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/PosSol/PRSolution2.cpp): `core/lib/PosSol/PRSolution2.cpp`
- [PPP Processing](https://github.com/sgl-ut/gnsstk/tree/stable/core/lib/Geomatics): `core/lib/Geomatics`
- [Integrity Monitoring](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/PosSol/PRSolution2.cpp): `core/lib/PosSol/PRSolution2.cpp`

### Core Foundation

- [Time Handling](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/TimeHandling/CommonTime.hpp): `core/lib/TimeHandling/CommonTime.hpp`
- [Satellite Geometry](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/SatID.hpp): `core/lib/GNSSCore/SatID.hpp`
- [Math Toolkit](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Math/Matrix/Matrix.hpp): `core/lib/Math/Matrix/Matrix.hpp`
- [Coordinates](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/GNSSCore/Position.hpp): `core/lib/GNSSCore/Position.hpp`
- [Application Framework](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/AppFrame/BasicFramework.hpp): `core/lib/AppFrame/BasicFramework.hpp`
- [Command Options](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/CommandLine/CommandOptionParser.cpp): `core/lib/CommandLine/CommandOptionParser.cpp`
- [Utilities](https://github.com/sgl-ut/gnsstk/blob/stable/core/lib/Utilities/StringUtils.hpp): `core/lib/Utilities/StringUtils.hpp`

### Other components

- **GNSS User**

## Connections

- GNSS User → GNSS Formats: supplies data
- GNSS Formats → Observation Data: provides observations
- GNSS Formats → Navigation Data: provides navigation
- Navigation Data → Navigation Filters: supports processing
- Observation Data → Time Handling: uses time
- Navigation Data → Ephemeris Models: supports calculations
- Observation Data → Pseudorange Ranging: supports ranging
- Ephemeris Models → Pseudorange Ranging: enables ranging
- Pseudorange Ranging → Position Solution: supports solution
- Atmospheric Models → Position Solution: models refraction
- Geodetic Models → PPP Processing: supports processing
- Observation Data → PPP Processing: processed by
- Navigation Data → PPP Processing: processed by
- Position Solution → Integrity Monitoring: includes integrity (evidence: `core/lib/PosSol/PRSolution2.cpp`)
- Time Handling → Coordinates: supports conversions
- Satellite Geometry → Ephemeris Models: identifies satellites
- Math Toolkit → Position Solution: supports algorithms (evidence: `core/lib/PosSol/PRSolution2.cpp`)
- GNSS User → Application Framework: uses applications
- Application Framework → Command Options: processes options
- Signal Corrections → Atmospheric Models: models delays
