Skip to content

Draft: combined pending PRs - #1252

Draft
svchb wants to merge 333 commits into
trixi-framework:mainfrom
svchb:bug_fixed
Draft

svchb wants to merge 333 commits into
trixi-framework:mainfrom
svchb:bug_fixed

Conversation

@svchb

@svchb svchb commented Jul 30, 2026 •

Copy link
Copy Markdown
Collaborator

This draft combines 18 open PRs and is based on main (2ad153ae1).

Pending PRs

Temporary PointNeighbors workaround

#1350 is deferred until PointNeighbors.jl #207 is released. To keep #1351 working with PointNeighbors 0.6.7, this draft uses the existing one-count API to reserve enough storage for both particle sets in precomputed searches. A nested trivial search still visits only the actual neighbor indices. The workaround covers both regular pair searches and the separate searches used for structure boundary corrections.

FSI integration

The structure boundary corrections use the current hydrodynamic neighborhood, independently of the total-Lagrangian solid-mechanics search. The shared fluid-pair operator gives the structure the opposite physical force, without including transport-only terms. For WCSPH with Adami or Bernoulli pressure extrapolation, the physical pressure force uses the fluid-side gradient for both pressure terms; TVF retains its separate inter-particle operator.

Verification

  • The PointNeighbors workaround passed all 510 neighborhood-search, semidiscretization, dummy-boundary, and boundary RHS checks with PointNeighbors 0.6.7 and bounds checks enabled. The unequal-count regression tests both particle-set orderings at initialization and after moving a neighbor.
  • Julia 1.11.9, two threads, bounds checks enabled: 851 focused checks passed, covering semidiscretization, structure summation density, open-boundary pressure mirroring, corrected WCSPH boundary pressure, and preprocessing point inputs.
  • All 100 EDAC system checks passed after adapting the pending correction-cache fix to the upstream correction-matrix API.
  • Aqua, JuliaFormatter 2.1.1, and git diff --check passed.

@codecov

codecov Bot commented Jul 30, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 95.71918% with 25 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.17%. Comparing base (2ad153a) to head (3e47421).

Files with missing lines Patch % Lines
src/general/gpu.jl 0.00% 3 Missing ⚠️
src/preprocessing/geometries/io.jl 57.14% 3 Missing ⚠️
src/preprocessing/geometries/polygon.jl 94.64% 3 Missing ⚠️
src/preprocessing/particle_packing/system.jl 70.00% 3 Missing ⚠️
src/setups/rectangular_tank.jl 80.00% 3 Missing ⚠️
...rc/schemes/fluid/entropically_damped_sph/system.jl 88.23% 2 Missing ⚠️
src/setups/extrude_geometry.jl 80.00% 2 Missing ⚠️
src/preprocessing/geometries/geometries.jl 96.55% 1 Missing ⚠️
src/preprocessing/geometries/triangle_mesh.jl 90.90% 1 Missing ⚠️
...boundary/wall_boundary/structure_boundary_model.jl 94.73% 1 Missing ⚠️
... and 3 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1252      +/-   ##
==========================================
+ Coverage   91.77%   92.17%   +0.39%     
==========================================
  Files         148      151       +3     
  Lines       11776    12199     +423     
==========================================
+ Hits        10808    11245     +437     
+ Misses        968      954      -14     
Flag Coverage Δ
total 92.17% <95.71%> (+0.39%) ⬆️
unit 84.61% <95.54%> (+2.36%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

svchb added 13 commits August 25, 2026 16:28
…geoms

# Conflicts:
#	src/callbacks/mechanical_work_calculator.jl
The third vertex of the inlet and outlet faces in
`examples/fluid/poiseuille_flow_3d.jl` spanned a diagonal edge, which is
rejected by the new orthogonality check in `spanning_vectors`.
Use the fourth corner of the rectangular cross-section instead, so that
both spanning edges are axis-aligned and orthogonal.
This also fixes the failing example tests
`fluid/poiseuille_flow_3d.jl (WCSPH)` and `fluid/pulsative_channel_flow_3d.jl`.
svchb added a commit that referenced this pull request Aug 31, 2026
@svchb

svchb commented Nov 10, 2026

Copy link
Copy Markdown
Collaborator Author

Review findings addressed in source PRs and remerged

All fixes were committed and pushed to their owning source PRs before merging the updated branches here:

Source PR Fix commit Resolution
#1351 95c5a66 Exclude rigid neighbors without hydrodynamic data from correction assembly/search updates while retaining mechanical contact forces.
#1199 cc4860f Include roundoff tolerance at boundary-sampling limits, including single-spacing layers.
#1190 6f1b91f Preserve the closing vertex and edge index when rebuilt polygon edges form a closed traversal.
#1187 c08eb16 Accept intentional two-edge open curves while retaining closed-region validation.
#1353 533b9f1 Fix the callback-test formatting failure with JuliaFormatter 2.1.1.

Combined head: cc9668e. The updated source heads are all ancestors of this branch. Changelog conflicts retained the existing combined entries without changing NEWS.md.

Combined verification

Julia 1.11.9, two threads, bounds checking:

  • Source-fix regression suites: 16,857/16,857 passed (dummy boundaries/contact, geometry, sampling, packing, callbacks, and neighborhood search).
  • Full fluid RHS/FSI file: 9,971/9,971 passed, run with --compile=min -O0.
  • Closed-vessel WCSPH pressure regression: 80/80 passed.
  • Correction-matrix regression: 39/39 passed.
  • Aqua checks passed with the repository default ambiguities=false and persistent_tasks=(tmax=120,).
  • JuliaFormatter 2.1.1: 100/100 changed Julia files passed; whitespace checks for the new changes passed.

This is focused combined-branch verification; the full unit/example/documentation/GPU suites were not rerun in this follow-up.

svchb added a commit that referenced this pull request Nov 10, 2026
svchb and others added 23 commits November 11, 2026 15:50
…ings

- Temporarily require `correction=nothing` for the `BoundaryModelDummyParticles` of a
  `TotalLagrangianSPHSystem` or `RigidBodySystem`. Their correction values require the
  complete current hydrodynamic neighborhood, which is added in trixi-framework#1351.
- Assemble the renormalized density gradient of `DensityDiffusionAntuono` from the
  uncorrected kernel gradient instead of the corrected fluid gradient, whose correction
  values are not computed yet when the density diffusion is updated.
- Allocate the dummy-particle correction caches with the element type of the density.
- Compute the kernel gradient of the boundary model once for the pressure acceleration
  and the continuity equation in the structure-fluid interaction.
- Define `system_correction` for `BoundaryModelDummyParticles` instead of a custom
  `smoothing_kernel_grad` method, so that the safe and unsafe gradients are consistent.
…re-boundary-correction-caches

# Conflicts:
#	NEWS.md
- Allow corrections of the `BoundaryModelDummyParticles` of structures again. The
  correction may differ from the fluid correction, but a boundary gradient that doesn't
  vanish at zero distance (`KernelCorrection`, `MixedKernelGradientCorrection`) requires
  every fluid to use such a correction, since pairs at the same position are skipped
  otherwise.
- With `SummationDensity`, compute the density of structure boundary models in every
  update with the kernel of the boundary model over the current hydrodynamic
  neighborhood. Previously, it kept its initial value, and `ShepardKernelCorrection`
  divided this value by the Shepard coefficient in every update.
- Reuse the regular structure-fluid searches for the hydrodynamic sums instead of
  creating and updating copies, and don't update searches of static walls.
- Rename the correction-specific search helpers to hydrodynamic search helpers, since
  they are also used for the density summation.
Like rigid bodies with only a contact model, a `TotalLagrangianSPHSystem` without
boundary model has no hydrodynamic density or mass. Including it in the correction values
or summation density of a structure boundary model failed with an error.
Use the upstream pressure-mirroring and boundary-kernel fixes, retain the pending follow-ups, and drop redundant preprocessing and documentation changes.
svchb added a commit that referenced this pull request Nov 23, 2026
Integrate PR #1252 and current main while preserving the separate correction API and rigid-body regression layout. Keep the temporary draft CI exception specific to #1252.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants