Skip to content

Commit 0d01e2e

Browse files
committed
update 29 Jan 2026 at 01:11
1 parent 5cd1674 commit 0d01e2e

7 files changed

Lines changed: 93 additions & 59 deletions

File tree

.gitatributes

Lines changed: 0 additions & 1 deletion
This file was deleted.

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.md linguist-detectable=true

.github/assets/js/search_db.json

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16862,21 +16862,21 @@
1686216862
},
1686316863
{
1686416864
"title": "Drop Impact Simulations | Drop Impact Simulations: Methods",
16865-
"content": "Key Features Adaptive Mesh Refinement : Quad/octree-based grids with automatic refinement at interfaces and high-velocity regions Two-Phase Flow : Volume-of-Fluid (VOF) method with surface tension modeling Axisymmetric Formulation : Efficient 2D simulations with cylindrical symmetry Modular Architecture : Separated parameter management, geometry initialization, and diagnostics HPC Ready : MPI parallel execution support for large-scale simulations Case-Based Organization : Automatic folder management with unique case numbers Quick Start Single Simulation # Edit parameters vim default.params # Set CaseNo, We, Oh, etc. # Run simulation (serial) ./runSimulation.sh # Run with MPI (4 cores) ./runSimulation.sh --mpi Parameter Sweep # Configure sweep vim sweep.params # Set CASE_START, CASE_END, sweep variables # Run sweep (serial) ./runParameterSweep.sh # Run sweep with MPI (4 cores per case) ./runParameterSweep.sh --mpi Repository Structure src-local/ - Modular header files params.h - Parameter structures and parsing geometry.h - Drop geometry and initialization diagnostics.h - Statistics and output handling postProcess/ - Post-processing tools and visualization getData-generic.c - Field extraction on structured grids getFacet.c - Interface geometry extraction getFootPrint.c - Footprint height analysis getFootPrint.py - Multi-cutoff footprint time-series plotFootPrint.py - Publication-quality footprint plots Video-generic.py - Frame-by-frame visualization pipeline simulationCases/ - Case-based simulation outputs dropImpact.c - Main simulation case runSimulation.sh - Single case runner runParameterSweep.sh - Parameter sweep runner default.params - Single-case configuration sweep.params - Sweep configuration Key Parameters Weber Number (We) : Ratio of inertial to surface tension forces Ohnesorge Numbers (Ohd, Ohs) : Viscous/surface tension ratios for drop and surrounding phases Reynolds Number : Re = \u221aWe/Oh Maximum Refinement Level : Controls mesh resolution (e.g., level 10 = 1024 cells) Domain Size : Computational domain size in drop radii Requirements Basilisk Framework : Install via the ref-locked script above (upstream docs: basilisk.fr ) MPI (optional): For parallel execution macOS: brew install open-mpi Linux: sudo apt-get install libopenmpi-dev References Key Publications Sanjay, V. & Lohse, D. (2025).",
16865+
"content": "Key Features Adaptive Mesh Refinement : Quad/octree-based grids with automatic refinement at interfaces and high-velocity regions Two-Phase Flow : Volume-of-Fluid (VOF) method with surface tension modeling Axisymmetric Formulation : Efficient 2D simulations with cylindrical symmetry Modular Architecture : Separated parameter management, geometry initialization, and diagnostics HPC Ready : MPI parallel execution support for large-scale simulations Case-Based Organization : Automatic folder management with unique case numbers Quick Start Single Simulation # Edit parameters vim default.params # Set CaseNo, We, Oh, etc. # Run simulation (serial) ./runSimulation.sh # Run with MPI (4 cores) ./runSimulation.sh --mpi Parameter Sweep # Configure sweep vim sweep.params # Set CASE_START, CASE_END, sweep variables # Run sweep (serial) ./runParameterSweep.sh # Run sweep with MPI (4 cores per case) ./runParameterSweep.sh --mpi Post-processing # Run post-processing on one or more cases ./runPostProcess-Ncases.sh 1000 1001 # Show available options ./runPostProcess-Ncases.sh --help Repository Structure src-local/ - Modular header files params.h - Parameter structures and parsing geometry.h - Drop geometry and initialization diagnostics.h - Statistics and output handling postProcess/ - Post-processing tools and visualization getData-generic.c - Field extraction on structured grids getFacet.c - Interface geometry extraction getFootPrint.c - Footprint height analysis getFootPrint.py - Multi-cutoff footprint time-series plotFootPrint.py - Publication-quality footprint plots Video-generic.py - Frame-by-frame visualization pipeline simulationCases/ - Case-based simulation outputs dropImpact.c - Main simulation case dropImpact_legacy.c - Legacy simulation source runSnellius_legacy.sbatch - Legacy batch script runSimulation.sh - Single case runner runParameterSweep.sh - Parameter sweep runner runPostProcess-Ncases.sh - Post-process multiple cases runSweepHamilton.sbatch - Hamilton batch script runSweepSnellius.sbatch - Snellius batch script default.params - Single-case configuration sweep.params - Sweep configuration Key Parameters Weber Number (We) : Ratio of inertial to surface tension forces Ohnesorge Numbers (Ohd, Ohs) : Viscous/surface tension ratios for drop and surrounding phases Reynolds Number : Re = \u221aWe/Oh Maximum Refinement Level : Controls mesh resolution (e.g., level 10 = 1024 cells) Domain Size : Computational domain size in drop radii Requirements Basilisk Framework : Install via the ref-locked script above (upstream docs: basilisk.fr ) MPI (optional): For parallel execution macOS: brew install open-mpi Linux: sudo apt-get install libopenmpi-dev References Key Publications Sanjay, V. & Lohse, D. (2025).",
1686616866
"url": "https://comphy-lab.org/Drop-Impact/index.html",
1686716867
"type": "docs_content",
1686816868
"priority": 4
1686916869
},
1687016870
{
1687116871
"title": "Drop Impact Simulations | Drop Impact Simulations: Unifying theory of...",
16872-
"content": "Unifying theory of scaling in drop impact: forces and maximum spreading diameter . Physical Review Letters, 134(10), 104003. DOI Comprehensive scaling theory for drop impact forces and maximum spreading Josserand, C. & Thoroddsen, S. T. (2016). Drop impact on a solid surface . Annual Review of Fluid Mechanics, 48, 365-391. DOI Comprehensive review of drop impact phenomena Yarin, A. L. (2006). Drop impact dynamics: Splashing, spreading, receding, bouncing\u2026 . Annual Review of Fluid Mechanics, 38, 159-192. DOI Classical review of drop impact dynamics Documentation Comprehensive documentation is available in CLAUDE.md , including: - Coding standards and best practices - Build and compilation instructions - Simulation physics and numerical methods - Parameter descriptions and typical values - Output file formats and visualization License See LICENSE file for details. Contributing This repository follows the CoMPhy Lab coding standards.",
16872+
"content": "Unifying theory of scaling in drop impact: forces and maximum spreading diameter . Physical Review Letters, 134(10), 104003. DOI Comprehensive scaling theory for drop impact forces and maximum spreading Josserand, C. & Thoroddsen, S. T. (2016). Drop impact on a solid surface . Annual Review of Fluid Mechanics, 48, 365-391. DOI Comprehensive review of drop impact phenomena Yarin, A. L. (2006). Drop impact dynamics: Splashing, spreading, receding, bouncing\u2026 . Annual Review of Fluid Mechanics, 38, 159-192. DOI Classical review of drop impact dynamics Documentation This README provides the user-facing overview and usage. Additional details live in the runnable scripts ( runSimulation.sh , runParameterSweep.sh ) and in the simulation source ( simulationCases/dropImpact.c ) and headers in src-local/ . License See LICENSE file for details. Contributing Follow the existing code style and keep changes consistent with the repository\u2019s structure and scripts.",
1687316873
"url": "https://comphy-lab.org/Drop-Impact/index.html",
1687416874
"type": "docs_content",
1687516875
"priority": 4
1687616876
},
1687716877
{
16878-
"title": "Drop Impact Simulations | Drop Impact Simulations: Context",
16879-
"content": "See CLAUDE.md for detailed guidelines on: - Code style (2-space indentation, 80-character lines) - Naming conventions (snake_case for variables, camelCase for functions) - Documentation requirements - Testing procedures Contact For questions or collaboration inquiries, please contact the CoMPhy Lab . Generated Documentation Root Directory default.params runParameterSweep.sh runPostProcess-Ncases.sh runSimulation.sh runSweepHamilton.sbatch runSweepSnellius.sbatch sweep.params postProcess postProcess/Video-generic.py postProcess/getData-generic.c postProcess/getFacet.c postProcess/getFootPrint.c postProcess/getFootPrint.py postProcess/plotFootPrint.py simulationCases simulationCases/dropImpact.c simulationCases/dropImpact_legacy.c simulationCases/runSnellius_legacy.sbatch src-local src-local/diagnostics.h src-local/geometry.h src-local/params.h src-local/parse_params.sh",
16878+
"title": "Drop Impact Simulations | Drop Impact Simulations: Contact For questions...",
16879+
"content": "Contact For questions or collaboration inquiries, please contact the CoMPhy Lab . Generated Documentation Root Directory default.params runParameterSweep.sh runPostProcess-Ncases.sh runSimulation.sh runSweepHamilton.sbatch runSweepSnellius.sbatch sweep.params postProcess postProcess/Video-generic.py postProcess/getData-generic.c postProcess/getFacet.c postProcess/getFootPrint.c postProcess/getFootPrint.py postProcess/plotFootPrint.py simulationCases simulationCases/dropImpact.c simulationCases/dropImpact_legacy.c simulationCases/runSnellius_legacy.sbatch src-local src-local/diagnostics.h src-local/geometry.h src-local/params.h src-local/parse_params.sh",
1688016880
"url": "https://comphy-lab.org/Drop-Impact/index.html",
1688116881
"type": "docs_content",
1688216882
"priority": 4
@@ -16916,6 +16916,20 @@
1691616916
"type": "docs_code",
1691716917
"priority": 4
1691816918
},
16919+
{
16920+
"title": "Drop Impact Simulations | Drop Impact Simulations - Code Example",
16921+
"content": "# Run post-processing on one or more cases./runPostProcess-Ncases.sh1000 1001",
16922+
"url": "https://comphy-lab.org/Drop-Impact/index.html",
16923+
"type": "docs_code",
16924+
"priority": 4
16925+
},
16926+
{
16927+
"title": "Drop Impact Simulations | Drop Impact Simulations - Code Example",
16928+
"content": "# Show available options./runPostProcess-Ncases.sh--help",
16929+
"url": "https://comphy-lab.org/Drop-Impact/index.html",
16930+
"type": "docs_code",
16931+
"priority": 4
16932+
},
1691916933
{
1692016934
"title": "sweep.params | Drop Impact Simulations: Context",
1692116935
"content": "sweep.params See raw file sweep.params # # sweep.params # Parameter sweep configuration for batch simulations. # ============================================================ # Base Configuration # ============================================================ # Start from this parameter file and override sweep variables BASE_CONFIG = default.params # ============================================================ # Case Number Range # ============================================================ # Starting case number (4-digit: 1000-9999) # Each parameter combination gets auto-incremented CaseNo CASE_START = 1306 # Ending case number (inclusive) # Number of combinations should equal CASE_END - CASE_START + 1 # For this sweep: 16 We \u00d7 16 Oh = 256 combinations, so CASE_END = 1561 CASE_END = 1561 # ============================================================ # Sweep Variables # ============================================================ # Format: SWEEP_<variable>=value1,value2,value3,... # The sweep will generate all combinations (cartesian product) # Sweep Weber number (vary impact velocity / surface tension) SWEEP_We = 50,60,70,80,90,100,126,158,200,251,316,398,501,631,794,1000 # Sweep Ohnesorge number (vary viscosity) SWEEP_Ohd = 1e-3,3e-3,1e-2,1.7e-2,2.9e-2,4.9e-2,8.4e-2,1.43e-1,2.43e-1,4.13e-1,7.02e-1,1.19,2.03,3.45,5.87,1e1 # Optional: sweep other parameters # SWEEP_MAXlevel=9,10,11 # SWEEP_Ldomain=6.0,8.0,10.0 # ============================================================ # Output Configuration # ============================================================ # Output folders are created in simulationCases/<CaseNo>/ # CaseNo auto-increments from CASE_START for each parameter combination # Cases run sequentially (one at a time)",

.github/scripts/generate_docs.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -429,13 +429,18 @@ def find_source_files(root_dir: Path, source_dirs: List[str]) -> List[Path]:
429429
"""
430430
valid_exts = {'.c', '.h', '.py', '.sh', '.sbatch', '.ipynb', '.params'}
431431
valid_names = {'Makefile'}
432+
# Exclude 4-digit numeric case folders (e.g., simulationCases/1000/)
433+
numeric_case_pattern = re.compile(r'/\d{4}/')
432434
files = set()
433435

434436
for dir_name in source_dirs:
435437
src_path = root_dir / dir_name
436438
if src_path.is_dir():
437439
for f in src_path.rglob('*'):
438440
if f.is_file():
441+
# Skip files in numeric case folders
442+
if numeric_case_pattern.search(str(f)):
443+
continue
439444
if f.name in valid_names:
440445
files.add(f)
441446
elif f.suffix in valid_exts and not f.name.endswith('.dat'):
@@ -478,7 +483,7 @@ def process_params_file(file_path: Path) -> str:
478483
Reads a parameter configuration file and returns its content as a Markdown-formatted INI code block.
479484
480485
Parameter files (.params) use key=value syntax with # for comments, similar to INI or shell configuration files.
481-
This format is used for simulation parameters in the Drop Impact project.
486+
This format is used for simulation parameters in CoMPhy Lab Basilisk projects.
482487
"""
483488
with open(file_path, 'r', encoding='utf-8') as f:
484489
content = f.read()

AGENTS.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# AGENTS
2+
3+
## Project Overview
4+
This repository contains Basilisk CFD simulation cases and post-processing
5+
tools for lid-driven cavity dye injection, plus generated documentation in
6+
`docs/`.
7+
8+
## Layout
9+
- `simulationCases/`: primary `.c` cases and Makefile
10+
- `src-local/`: project-specific headers
11+
- `postProcess/`: analysis scripts and notebooks
12+
- `docs/`: generated documentation site output
13+
- `.github/`: documentation assets, scripts, and workflows
14+
- `*.params`, `*.sbatch`: run configurations and cluster scripts
15+
- `basilisk/`: local Basilisk checkout (ignored; do not commit)
16+
17+
## Documentation workflow
18+
- Install Python deps: `python3 -m venv .venv && source .venv/bin/activate && pip install -r .github/scripts/requirements.txt`
19+
- Build docs: `.github/scripts/build.sh`
20+
- Preview locally: `.github/scripts/deploy.sh`
21+
22+
## Editing guidance
23+
- Do not commit the `basilisk/` directory or generated outputs outside `docs/`.
24+
- Keep case output directories untouched unless explicitly requested.
25+
- C/C++ style: 2-space indent, 80-char lines, use `/**` markdown comments (no leading `*` lines).

README.md

Lines changed: 15 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,18 @@ The codebase implements a classical lid driven cavity flow problem with dye inje
1313
## Repository Structure
1414

1515
```
16-
├── basilisk/src/ Core Basilisk CFD library (reference only, do not modify)
16+
├── basilisk/ Local Basilisk checkout (ignored; do not commit)
1717
├── simulationCases/ Test cases for simulation
1818
│ └── LidDrivenCavity-Newtonian-dyeInjection.c Lid-driven cavity with dye injection
1919
├── src-local/ Custom header files extending Basilisk functionality
2020
│ └── dye-injection.h Dye injection for flow visualization
2121
├── postProcess/ Project-specific post-processing tools
2222
│ ├── LidDrivenCavity-Newtonian-dyeInjection.ipynb Jupyter notebook for analysis
2323
│ ├── LidDrivenCavity-Newtonian-dyeInjection.py Python script for post-processing
24-
│ ├── Visualization3D.ipynb Jupyter notebook for 3D visualization
24+
│ ├── Visulization3D.ipynb Jupyter notebook for 3D visualization
2525
│ └── getData-LidDriven.c Data extraction utility
26+
├── docs/ Generated documentation site output
27+
├── .github/ Documentation assets, scripts, workflows
2628
├── runSweepHamilton.sbatch HPC batch script for Durham Hamilton cluster
2729
└── runSweepSnellius.sbatch HPC batch script for Snellius cluster
2830
```
@@ -52,6 +54,8 @@ The [`postProcess/`](postProcess) directory provides tools for analyzing and vis
5254
- Adds streamlines to visualize flow patterns
5355
- Uses 'getData-LidDriven' utility to extract field data
5456

57+
- [Visulization3D.ipynb](postProcess/Visulization3D.ipynb): Jupyter notebook for 3D visualization
58+
5559
- [getData-LidDriven.c](postProcess/getData-LidDriven.c): C utility that extracts and processes numerical data from simulation output files
5660

5761
### simulationCases/ Directory
@@ -82,8 +86,8 @@ These scripts run Stage 2 (MPI simulation) of parameter sweeps. Stage 1 (restart
8286
- Basilisk C installed ([Installation instructions](http://basilisk.fr/src/INSTALL))
8387
- C compiler (gcc recommended)
8488
- Make build system
85-
- Python 3 with pip for documentation generation
86-
- BeautifulSoup4 for HTML processing (included in requirements.txt)
89+
- Python 3 with pip for documentation generation (see `.github/scripts/requirements.txt`)
90+
- Pandoc for HTML generation used by `.github/scripts/generate_docs.py`
8791
- Scientific visualization tools (optional: ParaView, Gnuplot, etc.)
8892

8993
### Installation
@@ -96,14 +100,11 @@ These scripts run Stage 2 (MPI simulation) of parameter sweeps. Stage 1 (restart
96100

97101
2. Make sure Basilisk is properly installed and the BASILISK environment variable is set.
98102

99-
3. Install Python dependencies (uses a virtual environment):
103+
3. Install Python dependencies for documentation generation:
100104
```bash
101-
# This will automatically set up a virtual environment and install dependencies
102-
# like BeautifulSoup4 for HTML processing
103-
./reset_install_requirements.sh
104-
105-
# To activate the virtual environment for manual commands:
105+
python3 -m venv .venv
106106
source .venv/bin/activate
107+
pip install -r .github/scripts/requirements.txt
107108
```
108109

109110
4. Compile a test case to verify the setup:
@@ -281,16 +282,9 @@ Please include:
281282
- Additional functionality in the codebase
282283
- Improvements to existing materials
283284
284-
#### Example Request:
285-
[Report here](https://github.com/comphy-lab/documentationWeb/issues/new?template=example_request.md)
286-
- For requesting specific examples that demonstrate:
287-
- Particular Basilisk features
288-
- Solutions to common problems
289-
- Implementation of specific physics or numerical methods
290-
291-
#### General Question:
292-
[Report here](https://github.com/comphy-lab/documentationWeb/issues/new?template=general_question.md)
293-
- For any other questions
285+
#### Question/Discussion:
286+
[Report here](https://github.com/comphy-lab/documentationWeb/issues/new?template=question.md)
287+
- For any other questions or discussions
294288
295289
### How to Create an Issue
296290
@@ -307,4 +301,4 @@ This project is licensed under the [GNU General Public License v3.0](LICENSE) -
307301
308302
## Acknowledgments
309303
310-
- S. Popinet & collaborators, Basilisk C, [http://basilisk.fr](http://basilisk.fr) (Last accessed: June 2025) (2013-2025)
304+
- S. Popinet & collaborators, Basilisk C, [http://basilisk.fr](http://basilisk.fr) (Last accessed: June 2025) (2013-2025)

0 commit comments

Comments
 (0)