Skip to content

Cross-validation against Echoes

MeanFieldHomogenization is a port of the C++ Echoes code, so nearly every quantity has an independent reference. The cross-checks live in scripts/bench_echoes/ and call Echoes through PyCall (setup: From Echoes to MeanFieldHomogenization); the ALV ones also ship *_python.json dumps so they run without an Echoes install.

Cross-checks

ScriptValidatedTolerance
benchmark.jl, (residues, DECUHR), machine (aniso), ~1e-6 (iso)
benchmark_nlayers.jln-layer averages , local fields1e-6
benchmark_porous.jlporous moduli, 10 schemes × 2 shapes × 7 porosities1e-6
benchmark_strength.jlmortar + strength [72]1 % / 2 %
benchmark_hill_derivative.jl (ISO, ORTHO)1e-5 / 1e-4

Agreement measured

QuantityAgreement
Hill , anisotropic (same residue algorithm both sides)machine precision
Hill , isotropic (analytic vs quadrature)1e-6 … 1e-8
ISO 1e-15, ORTHO 1e-6
Crack , pennymachine precision
Porous moduli — Voigt, Reuss, Dilute, DiluteDual, Maxwell, PCW, MT2.5e-14
Porous moduli — SC,  5.7e-7
n-layer sphere / (30 random 2–8-layer stacks)4.6e-13 / 4.4e-14
n-layer sphere, local (80 points)5.8e-16
Rotational averages TI / ISO (C++ transcribed verbatim)1e-12
ALV per-layer , 1e-16 diag, 1e-6 off-diag
Dual-interface concentrations / effective diffusivity1e-8 / 1e-5
Cracked ALV creep, PCW / SC + interface1e-4 / 1.4e-4
Three-scale mortar 1e-3

Deliberate divergences

Conventions and formulation choices, not numerical error — do not "fix" them.

DivergenceNatureExplained in
Elliptic crack normalization, see belowCOD tensors
MT on a cracked RVE  vs additive closure; both agree with PCW at low densityViscoelasticity
ASC, porous oblateEchoes' compliance-form ASC converges to another branchbenchmark_porous.jl
DifferentialScheme, porous  pre-existing gap, 2.6e-3 → 6.2e-2, reproduciblebenchmark_porous.jl
Strength (2 %)water/air regularized to a small positive stiffnessStrength

MeanFieldHomogenization normalizes the crack compliance by the minor semi-axis , Echoes by the major semi-axis , so for an in-plane aspect ratio  :

Verified at  : the ratio is to four decimals, and the is -independent to machine precision.

Degenerate cases hide conventions

At   both conventions coincide, and a localization term that vanishes in every symmetric configuration is invisible to a test suite built from those configurations. See Testing conventions.

Running

julia
import DECUHR, Integrals      # the :decuhr back-end lives in an extension
include("scripts/bench_echoes/benchmark.jl")