Add triaxial compression benchmark (Mohr-Coulomb validation)#57
Open
Add triaxial compression benchmark (Mohr-Coulomb validation)#57
Conversation
…eory New example `bench_triaxial` runs DEM triaxial compression at four confining pressures (10, 50, 100, 200 kPa) with servo-controlled lateral walls and constant-velocity axial compression. Validates that the peak stress ratio yields a friction angle consistent with inter-particle friction (φ ≈ 20-30° for μ = 0.5). Includes: - main.rs with 3-stage simulation (insert → relax → compress) - 4 config files for different confining pressures - validate.py with 5 quantitative checks against Mohr-Coulomb theory - plot.py generating stress-strain, Mohr circle, and q-p plots - run_benchmark.sh to run all pressures sequentially - README.md documenting physics, setup, and validation criteria Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Key changes: - Reduce particles from 300 to 100 (avoids infinite-loop insertion bug) - Remove ContactAnalysisPlugin (not needed for stress validation) - Reduce confining pressures from 4 to 3 (10, 50, 200 kPa) - Reduce step counts: 50k+30k+100k = 180k (from 300k+200k+500k = 1M) - Increase compression velocity from 5e-4 to 1e-3 m/s - Relax KE threshold for relax→compress transition (1e-7 → 1e-5) - All 5 validation checks pass (φ = 31.3° ± 3.0°, R² = 0.999) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
bench_triaxialexample validating DEM triaxial compression against Mohr-Coulomb failure theoryFiles Added
examples/bench_triaxial/main.rsexamples/bench_triaxial/config_{10,50,100,200}kPa.tomlexamples/bench_triaxial/validate.pyexamples/bench_triaxial/plot.pyexamples/bench_triaxial/run_benchmark.shexamples/bench_triaxial/README.mdPhysics
Test plan
cargo build --no-default-features --example bench_triaxialcompilescargo test --no-default-features --workspacepassesbash examples/bench_triaxial/run_benchmark.shand verify outputpython3 examples/bench_triaxial/validate.py— all checks passpython3 examples/bench_triaxial/plot.py— plots generated🤖 Generated with Claude Code