Skip to content

Commit

Permalink
Add all the other typically used smoothing kernels for SPH (#237)
Browse files Browse the repository at this point in the history
* add gaussian kernels

* add all the other ones

* format

* fix

* format

* fixes

* fix

* add testcase and fix wendlandc4

* format

* add QuadGK

* update

* format

* Fix tests

* review

* format

* [skip ci] add information regarding smoothing L

* fix docs

* code review

* [skip ci] fix table

* [skip ci] change table

* revert change

* [skip ci]

* [skip ci] review
  • Loading branch information
svchb authored Nov 10, 2023
1 parent e2c2422 commit 6e5d5d1
Show file tree
Hide file tree
Showing 6 changed files with 508 additions and 9 deletions.
6 changes: 3 additions & 3 deletions examples/fluid/dam_break_2d.jl
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ using OrdinaryDiffEq
fluid_particle_spacing = 0.02

# Change spacing ratio to 3 and boundary layers to 1 when using Monaghan-Kajtar boundary model
boundary_layers = 3
boundary_layers = 4
spacing_ratio = 1

boundary_particle_spacing = fluid_particle_spacing / spacing_ratio
Expand All @@ -39,8 +39,8 @@ tank = RectangularTank(fluid_particle_spacing, initial_fluid_size, tank_size, fl

# ==========================================================================================
# ==== Fluid
smoothing_length = 1.2 * fluid_particle_spacing
smoothing_kernel = SchoenbergCubicSplineKernel{2}()
smoothing_length = 3.0 * fluid_particle_spacing
smoothing_kernel = WendlandC2Kernel{2}()

fluid_density_calculator = ContinuityDensity()
viscosity = ArtificialViscosityMonaghan(alpha=0.02, beta=0.0)
Expand Down
3 changes: 2 additions & 1 deletion src/TrixiParticles.jl
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ export InfoCallback, SolutionSavingCallback, DensityReinitializationCallback
export ContinuityDensity, SummationDensity
export PenaltyForceGanzenmueller
export SchoenbergCubicSplineKernel, SchoenbergQuarticSplineKernel,
SchoenbergQuinticSplineKernel
SchoenbergQuinticSplineKernel, GaussianKernel, WendlandC2Kernel, WendlandC4Kernel,
WendlandC6Kernel, SpikyKernel, Poly6Kernel
export StateEquationIdealGas, StateEquationCole
export ArtificialViscosityMonaghan, ViscosityAdami
export BoundaryModelMonaghanKajtar, BoundaryModelDummyParticles, AdamiPressureExtrapolation,
Expand Down
Loading

0 comments on commit 6e5d5d1

Please sign in to comment.