feat(fem): second moment of area of a hollow circular (tube) section#442
Merged
Merged
Conversation
Add beam::hollow_circular_second_moment_of_area(outer_diameter, inner_diameter), the bending second moment of a tube/pipe cross-section: I = pi * (D^4 - d^4) / 64 (m^4) the annulus = outer disc minus inner disc -- the I of structural tubing, far stiffer per unit weight than a solid bar since the removed core carries little bending stress. Guard: D > 0, 0 <= d < D, finite. Analytic test hollow_circular_second_moment_of_area_is_pi_d4_minus_d4_over_64: (a) worked D=0.1, d=0.05 -> I ~= 4.6019e-6 m^4; (b) threads circular_second_moment_of_area (#419) (non-tautological): the annulus is I(D) - I(d); (c) solid limit: a zero bore is a solid circle; (d) monotonicity: a larger bore removes more material so I drops; (e) 0-sentinel guards for D<=0, d>=D, non-finite, negative bore. Re-exported from lib.rs alphabetically in the beam block. valenx-fem 265 lib tests (was 264), cargo clippy --all-targets -D warnings clean.
nochallenge
added a commit
that referenced
this pull request
Jun 9, 2026
… set (#451) Adds the shear modulus (modulus of rigidity) G = E/(2(1+ν)) (Pa) as a public closed-form primitive in beam.rs — the second Lamé constant μ, relating a shear stress to the shear strain it produces. Together with the bulk modulus K (#440) and the Lamé first parameter λ (#442) it completes the isotropic elastic-constant set: λ = K − 2G/3, and E = 9KG/(3K+G). Named shear_modulus_from_youngs to avoid colliding with the crate's existing private material-based shear_modulus(&FemMaterial) helper; the new fn is the closed-form (E, ν) → f64 public companion. Returns 0 for non-physical input (E ≤ 0 or non-finite, ν outside (−1, 0.5)); G > 0 throughout that range, so the 0 sentinel is unambiguous. Analytic test (5 checks): worked anchor (E=200e9, ν=0.3 → G≈7.6923e10); two non-tautological cross-checks threading the prior constants — the Lamé identity G = 1.5(K − λ) and the interconversion E = 9KG/(3K+G); the ν=0 limit G = E/2; and non-physical guards → 0. valenx-fem 269 lib tests (was 268), clippy clean. Research-grade closed-form, not a substitute for a full constitutive model.
nochallenge
added a commit
that referenced
this pull request
Jun 9, 2026
…amily (#453) Adds the P-wave (longitudinal / constrained) modulus M = E(1−ν)/((1+ν)(1−2ν)) (Pa) as a public closed-form primitive in beam.rs — the uniaxial-strain stiffness (stress to compress along one axis while laterally constrained, as in an oedometer / 1-D consolidation test), which also sets the compressional wave speed v_p = √(M/ρ). It is the capstone tying the whole isotropic elastic-constant family together: M = K + 4G/3 = λ + 2G, where K = bulk_modulus (#440), G = shear_modulus_from_youngs (#444), λ = lames_first_parameter (#442). At ν=0 it reduces to E. Returns 0 for non-physical input (E ≤ 0 or non-finite, ν outside (−1, 0.5)); M > 0 throughout that range, so the 0 sentinel is unambiguous. Analytic test (5 checks): worked anchor (E=200e9, ν=0.3 → M≈2.6923e11); two exact non-tautological identities threading the prior constants — M = K + 4G/3 and M = λ + 2G (the latter ties all four together); the ν=0 limit M = E; and non-physical guards → 0. valenx-fem 270 lib tests (was 269), clippy clean. Research-grade closed-form, not a substitute for a full constitutive model.
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.
What
Adds
beam::hollow_circular_second_moment_of_area(outer_diameter, inner_diameter)— the bending second moment of a tube/pipe cross-section:// I = pi * (D^4 - d^4) / 64 (m^4)Why
The annulus = outer disc minus inner disc — the
Iof structural tubing, far stiffer per unit weight than a solid bar since the removed core carries little bending stress. Guard:D > 0,0 <= d < D, finite. Extends the FEM section-property library from solid sections to hollow tubing.Test
hollow_circular_second_moment_of_area_is_pi_d4_minus_d4_over_64:D=0.1, d=0.05 -> I ~= 4.6019e-6 m^4;circular_second_moment_of_area(feat(cfd): vorticity standard deviation (variance identity) #419) (non-tautological) — the annulus isI(D) - I(d);Idrops;D<=0,d>=D, non-finite, negative bore.Re-exported from
lib.rsalphabetically in the beam block.valenx-fem265 lib tests (was 264);cargo clippy -p valenx-fem --all-targets -- -D warningsclean. Research-grade section-property primitive.