Skip to content

Commit b8beca6

Browse files
author
LasNikas
committed
Merge branch 'main' into oriented-bbox
2 parents 196785c + ce2edcb commit b8beca6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+1693
-555
lines changed

.github/workflows/SpellCheck.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ jobs:
1010
- name: Checkout Actions Repository
1111
uses: actions/checkout@v5
1212
- name: Check spelling
13-
uses: crate-ci/typos@v1.35.7
13+
uses: crate-ci/typos@v1.37.0

NEWS.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,16 @@ used in the Julia ecosystem. Notable changes will be documented in this file for
99
### Features
1010

1111
- Added an incompressible SPH solver `ImplicitIncompressibleSPHSystem` (#751).
12+
- Added `SplitIntegrationCallback` to integrate the `TotalLagrangianSPHSystem`s
13+
in a `Semidiscretization` separately from the other systems (#794).
1214

15+
### Important Bugfixes
1316

17+
- Fixed `kernel_grad` threshold with single precision and small particle spacing (#913).
18+
- Fixed error with `UpdateCallback` when `SaveSolutionCallback` comes first in the
19+
`CallbackSet` (#924).
20+
- Fixed error when using shifting techniques without `UpdateCallback` (#925).
21+
- Updated program flow diagram (#917).
1422

1523
## Version 0.4
1624

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "TrixiParticles"
22
uuid = "66699cd8-9c01-4e9d-a059-b96c86d16b3a"
33
authors = ["erik.faulhaber <44124897+efaulhaber@users.noreply.github.com>"]
4-
version = "0.4.1-dev"
4+
version = "0.4.2-dev"
55

66
[deps]
77
Adapt = "79e6a3ab-5dfb-504d-930d-738a2a938a0e"

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ It offers intuitive configuration, robust pre- and post-processing, and vendor-a
2828

2929
## Features
3030
- Incompressible Navier-Stokes
31-
- Methods: Weakly Compressible Smoothed Particle Hydrodynamics (WCSPH), Entropically Damped Artificial Compressibility (EDAC)
31+
- Methods: Weakly Compressible Smoothed Particle Hydrodynamics (WCSPH),
32+
Entropically Damped Artificial Compressibility (EDAC),
33+
Implicit Incompressible SPH (IISPH)
3234
- Models: Surface Tension, Open Boundaries
3335
- Solid-body mechanics
3436
- Methods: Total Lagrangian SPH (TLSPH), Discrete Element Method (DEM)

docs/Project.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Asciicast = "2600d445-abca-43b9-92aa-ce144ac0b05b"
33
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
44
DocumenterCitations = "daee34ce-89f3-4625-b898-19384cb65244"
5+
DocumenterMermaid = "a078cd44-4d9c-4618-b545-3ab9d77f9177"
56
Literate = "98b081ad-f1c9-55d3-8b20-4c87d4299306"
67
OrdinaryDiffEq = "1dea7af3-3e70-54e6-95c3-0bf5283fa5ed"
78
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
@@ -10,6 +11,7 @@ Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
1011
Asciicast = "0.1.3"
1112
Documenter = "1"
1213
DocumenterCitations = "1"
14+
DocumenterMermaid = "0.2"
1315
Literate = "2"
1416
OrdinaryDiffEq = "6"
1517
Plots = "1"

docs/literate/src/tut_packing.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ background_pressure = 1.0
140140

141141
# For particle interaction, we select a [smoothing kernel](@ref smoothing_kernel)
142142
# with a suitable smoothing length. Empirically, a factor of `0.8` times the
143-
# particle spacing gives good results [neher2025robustefficientpreprocessingtechniques](@cite).
143+
# particle spacing gives good results [Neher2025](@cite).
144144
smoothing_kernel = SchoenbergQuinticSplineKernel{2}()
145145
smoothing_length = 0.8 * particle_spacing
146146

@@ -203,7 +203,7 @@ plot(packed_ic)
203203
plot!(geometry, seriestype=:path, color=:black, label=nothing, linewidth=2)
204204

205205
# We can see that the particles now stay inside the geometry,
206-
# but their distribution near the surface can still be improved by adding boundary particles [neher2025robustefficientpreprocessingtechniques](@cite).
206+
# but their distribution near the surface can still be improved by adding boundary particles [Neher2025](@cite).
207207
# Therefore, we set up a dedicated boundary packing system
208208
# by setting `is_boundary = true`.
209209
# For convex geometries, it is useful to slightly compress the

docs/make.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
using Documenter, DocumenterCitations
1+
using Documenter, DocumenterCitations, DocumenterMermaid
22
using TrixiParticles
33
using TrixiParticles.TrixiBase
44
using TrixiParticles.PointNeighbors

docs/src/overview.md

Lines changed: 58 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,65 @@ During a single time step or an intermediate step of the time integration scheme
1717
`drift!` and `kick!` are invoked, followed by the functions depicted in this diagram
1818
(with key parts highlighted in orange/yellow).
1919

20-
![Main Program Flow](https://github.com/trixi-framework/TrixiParticles.jl/assets/10238714/d7c6eedd-7173-4879-b62e-3e6d4bc5091f)
20+
```mermaid
21+
%% Make arrows bend at right angles
22+
%%{ init : { "flowchart" : { "curve" : "stepAfter" }}}%%
2123
24+
%% TD means vertical layout
25+
flowchart TD
26+
%% --- Define color palette and styles ---
27+
classDef start_node fill:#d9ead3,stroke:#333,color:#333
28+
classDef time_integration fill:#d9d2e9,stroke:#333,color:#333
29+
classDef primary_stage fill:#cfe2f3,stroke:#333,color:#333
30+
classDef update fill:#eeeeee,stroke:#333,color:#333
31+
classDef updates fill:#fff2cc,stroke:#333,color:#333
32+
classDef physics fill:#fce5cd,stroke:#333,color:#333
33+
34+
A(simulation) --> B[time integration];
35+
36+
%% Add hidden dummy node to branch the arrow nicely
37+
B --- dummy[ ];
38+
style dummy width:0;
39+
dummy --> C["drift!<br/>(update du/dt)"];
40+
41+
subgraph kick["<div style='padding: 10px; font-weight: bold;'>kick! (update dv/dt)</div>"]
42+
%% Horizontal layout within this subgraph
43+
direction LR;
44+
45+
subgraph updates["<div style='padding: 10px; font-weight: bold;'>update_systems_and_nhs</div>"]
46+
%% Vertical layout within this subgraph
47+
direction TB;
48+
49+
H["update_positions!<br/>(moving boundaries and structures)"];
50+
I["update_nhs!<br/>(update neighborhood search)"];
51+
J["update_quantities!<br/>(recalculate density etc.)"];
52+
K["update_pressure!<br/>(recalculate pressure etc.)"];
53+
L["update_boundary_interpolation!<br/>(interpolate boundary pressure)"];
54+
M["update_final!<br/>(update shifting)"];
55+
56+
H --> I --> J --> K --> L --> M;
57+
end
58+
59+
F["system_interaction!<br/>(e.g. momentum/continuity equation)"];
60+
G["add_source_terms!<br/>(gravity and source terms)"];
61+
62+
updates --> F --> G;
63+
end
64+
65+
dummy --> kick;
66+
67+
%% Color the sub-tasks by their function
68+
class A start_node;
69+
class B time_integration;
70+
class C primary_stage;
71+
class kick primary_stage;
72+
class updates update;
73+
class H,I,J,K,L,M updates;
74+
class F,G physics;
75+
76+
%% Style the arrows
77+
linkStyle default stroke-width:2px,stroke:#555
78+
```
2279

2380
## Structure
2481
What we refer to as schemes are various models such as Weakly Compressible Smoothed Particle Hydrodynamics (WCSPH)

docs/src/preprocessing/preprocessing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ Pages = [joinpath("preprocessing", "geometries", "io.jl")]
302302
```
303303

304304
# [Particle Packing](@id particle_packing)
305-
To obtain a body-fitted and isotropic particle distribution, an initial configuration (see [Sampling of Geometries](@ref sampling_of_geometries)) is first generated. This configuration is then packed using a [`ParticlePackingSystem`](@ref) following the steps introduced in [neher2025robustefficientpreprocessingtechniques](@cite).
305+
To obtain a body-fitted and isotropic particle distribution, an initial configuration (see [Sampling of Geometries](@ref sampling_of_geometries)) is first generated. This configuration is then packed using a [`ParticlePackingSystem`](@ref) following the steps introduced in [Neher2025](@cite).
306306
For a hands-on tutorial with complete examples, see the particle packing tutorial.
307307
The preprocessing pipeline consists of the following steps:
308308

0 commit comments

Comments
 (0)