Xiangyu-Hu / SPHinXsys

SPHinXsys provides C++ APIs for engineering simulation and optimization. It aims at complex systems driven by fluid, structure, multi-body dynamics and beyond. The multi-physics library is based on a unique and unified computational framework by which strong coupling has been achieved for all involved physics.
https://www.sphinxsys.org/
Apache License 2.0
259 stars 199 forks source link

Remove fluid particles -- done #326

Closed Shuaihao-Zhang closed 11 months ago

Shuaihao-Zhang commented 11 months ago

refer to #317 Four files have been removed: fluid_particles.h fluid_particles.cpp fluid_particles_variable.h fluid_particles_variable.cpp

DrChiZhang commented 11 months ago

@Shuaihao-Zhang Shuaihao, would you please briefly present the idea underlying this modification?

Shuaihao-Zhang commented 11 months ago

@Shuaihao-Zhang Shuaihao, would you please briefly present the idea underlying this modification?

Sure. After discussing with Prof. Hu, we think it's better to register all the variables in the dynamics part rather than in the particles. We just need BaseParticles, and the FluidParticlesand SolidParticles are not needed.

Here is one of the reason why using FluidParticles and SolidParticles is not good:

FluidParticles can only be used in fluid_dynamics, and SolidParticles can only be used in solid_dynamics. But for some specific situations, we want to use the functions both in fluid_dynamics and solid_dynamics. Then I don't know which particle should I defined for the materials. For example, when I simulate the case colliding_rubber_ringbased on update Lagrange method, I need to use the BaseIntegration1stHalf in the fluid_dynamicsand also the ContactForce in contact_dynamics.

Since there are too many variables in SolidParticles, so currently I just remove FluidParticles first.

Shuaihao-Zhang commented 11 months ago

For the fluid variables, only the pressureis registered in the material Fluid. SurfaceIndicatoris registered in the BaseParticles. DensityChangeRateand DensitySummationare registered at the fluid_dynamics.

Xiangyu-Hu commented 11 months ago

@ZhentongWang Within this pull request, fluid particles has been removed. Now there are some conflict with your merged code on FVM formulation. Could you help to solve the conflict? Thanks.