#+TITLE: Holst
#+AUTHOR: Charles Kralapp
#+OPTIONS: toc:nil num:nil

This project combines a raytracing in one weekend style raytracer and an N-body solar system simulation to learn modern C++ (C++03–C++23) through practical implementation.

* ✅ Project Goals
- [X] Simulate solar system using an N-body gravitational algorithm.
- [X] Implement a raytracer for rendering bodies and backgrounds.
- [ ] Learn and demonstrate features from every major C++ standard.

* 📚 C++ Learning Checklist

** C++03 (Baseline)
- [X] Classes & Constructors
- [X] Operator Overloading (`+`, `*`, `[]`)
- [X] Manual memory management (`new` / `delete`)
- [X] STL containers: `std::vector`, `std::map`
- [ ] Function overloading
- [X] Templates (vector math, utility classes)
- [X] Pointers, references, and const correctness
- [ ] Namespaces
- [X] RAII pattern with destructors
- [X] `std::string`, `std::stringstream`

** C++11 (Modern C++ begins)
- [X] `auto` type deduction
- [X] Range-based for loops
- [ ] Lambda expressions
- [X] `nullptr`
- [ ] `enum class`
- [X] Smart pointers: `std::unique_ptr`, `std::shared_ptr`
- [ ] `override`, `final` specifiers
- [ ] `move` semantics and rvalue references
- [X] `std::array`, `std::tuple`
- [X] Thread support: `std::thread`

** C++14 (Polish & convenience)
- [ ] Generic lambdas (`auto` in lambda parameters)
- [ ] `decltype(auto)` and improved return type inference
- [ ] `std::make_unique`
- [ ] Binary literals and digit separators (`0b1010`, `1'000'000`)
- [X] Relaxed constexpr functions
- [ ] Using `auto` in lambda captures

** C++17 (Simpler and more expressive)
- [ ] Structured bindings (`auto [x, y] = foo();`)
- [ ] `if constexpr`
- [ ] `std::optional`
- [ ] `std::variant`, `std::any`
- [ ] Inline variables
- [ ] `std::string_view`
- [ ] Filesystem support (`std::filesystem`)
- [ ] Parallel algorithms (`std::execution`)

** C++20 (Huge leap forward)
- [ ] Concepts (`template<typename T> requires`)
- [ ] Ranges library: views, filters, transforms
- [ ] `consteval` / `constinit`
- [ ] Coroutines (`co_yield`, `co_return`)
- [ ] Calendar and time utilities (`std::chrono::year_month_day`)
- [ ] Modules (if supported by compiler/toolchain)
- [ ] Expanded constexpr support (e.g., STL algorithms)

** C++23 (Final polish)
- [X] `std::expected` (like Rust's Result<T, E>)
- [ ] `std::mdspan` for multidimensional array views
- [ ] `explicit` lambdas
- [ ] More constexpr in the standard library
- [ ] `[[assume]]` attribute
- [ ] Improved ranges (e.g., `views::repeat`, `zip`)

* 🛠 Project Milestones (use standards progressively)

** Milestone 1: Base Simulation Engine
- [ ] Build N-body simulation using raw pointers (C++03)
- [ ] Add `Vector3` class, `Body` class
- [ ] Use `std::vector` and manual memory management

** Milestone 2: Modernization Pass 1
- [ ] Convert raw pointers to smart pointers (C++11)
- [ ] Add lambda-driven physics update loop
- [ ] Use `enum class` for material types

** Milestone 3: Raytracer Core
- [ ] Add ray-object intersection logic
- [ ] Use `std::optional` for hit results (C++17)
- [ ] Structured bindings for clean code

** Milestone 4: Optimization Pass
- [ ] Parallel rendering with `std::execution::par` (C++17)
- [ ] Use ranges and views to process pixels (C++20)

** Milestone 5: Error Handling & Final Touches
- [ ] Use `std::expected` for config file errors or simulation errors (C++23)
- [ ] Add diagnostics/metrics via coroutines or logging views
- [ ] Final cleanup using `consteval`, `mdspan`, or advanced features
