How daisy-model/daisy works
Project type and purpose
• Daisy is an open-source scientific simulation framework written in C++.
• It models soil–plant–atmosphere processes (chemistry, transport, crop growth, organic matter).
• It provides a command-line interface (CLI), a Python binding, and a plugin-style library of scenario definitions.
File structure
• Top-level build and config:
• CMakeLists.txt, CMakePresets.json, .github/workflows, packaging (cpack)
• Core code in src/ and include/:
• Domain modules (chemicals, crop, soil/transport, upper_boundary, lower_boundary, organic_matter)
• Object model & parser for reading DAI scenario files
• Utility and solver support (SuiteSparse, Boost, math libraries)
• UI layer (CLI in src/ui, Python interface in python/)
• Gnuplot integration for plotting
• Programs/ executables in src/programs/
• Library of pre-built scenarios in lib/
• Samples and tests separate application data, system tests, unit tests
README insights
• Build system: CMake presets for Linux/macOS/Windows, dependencies (Boost, suitesparse, pybind11)
• Python support via pybind11 and embedded interpreter (windows workaround)
• Test harness driven by ctest and external Python test suite
Diagramming recommendations
• Clear labels for each component block (Build, Parser, Core Engine, Modules, Interfaces, Tests)
• Build & CI (e.g., gray)
• Core modules (blue)
• Interfaces (green)
• External dependencies (orange)
• Tests & samples (purple)