Caerula (Fall 2025) is a Stochastic Monte Carlo Ray Tracing system for simulating ocean optical sensors. Built in Rust for performance, it includes Python bindings for analysis.

Source code and documentation: Hamza-Anver/caerula-rs.

Overview

Caerula models underwater light propagation by tracing rays through a medium. It accounts for scattering and absorption based on properties such as turbidity and chlorophyll-a concentration, simulating sensor detection across various conditions.

Components:

  • caerula-engine: Core ray tracing engine (Rust).
  • caerula-cli: CLI for scene testing.
  • caerula-py: Python bindings for data analysis (e.g., Pandas, Plotly).

Implementation

The engine uses a Monte Carlo approach, tracing rays from source to sensor. While computationally intensive, this method adapts well to mathematical models of underwater light propagation.

Key features:

  • Medium: Configurable turbidity and chlorophyll levels.
  • Source: Adjustable sunlight position, direction, intensity, and spread.
  • Sensor: Configurable dimensions, FOV, and spectral sensitivity.
  • Spectra: Simulation across wavelengths (e.g., 400nm - 700nm).

Validation

The engine was validated against physical laws and experimental data.

Beer-Lambert Law Simulation results (red) match the theoretical exponential decay (dashed grey).

Geometric Attenuation Validation of the Inverse Square Law for point sources.

Hardware Geometry Visual representation of the physical simulation setup.

Documentation

Future Work

  • Surface model (refraction/reflection).
  • GPU acceleration.
  • Complex geometries.

Capstone project at NYU Abu Dhabi.