Skip to content
Snippets Groups Projects
Commit d820e7f2 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Allow for different velocity and pressure fields

parent 80b371bd
No related branches found
No related tags found
1 merge request!208Test 125
......@@ -32,6 +32,7 @@
/* Local includes. */
#include "config.h"
#include "const.h"
#include "hydro.h"
#include "inline.h"
#include "part.h"
......
......@@ -55,56 +55,52 @@ struct part {
/* Particle density. */
float rho;
/* Derivative of the density with respect to this particle's smoothing length.
*/
float rho_dh;
/* Particle entropy. */
float entropy;
/* Derivative of the density with respect to smoothing length. */
/* Derivative of the density with respect to smoothing length. */
float rho_dh;
union {
// union {
struct {
struct {
/* Number of neighbours. */
float wcount;
/* Number of neighbours. */
float wcount;
/* Number of neighbours spatial derivative. */
float wcount_dh;
/* Number of neighbours spatial derivative. */
float wcount_dh;
/* Particle velocity curl. */
float rot_v[3];
/* Particle velocity curl. */
float rot_v[3];
/* Particle velocity divergence. */
float div_v;
/* Particle velocity divergence. */
float div_v;
} density;
} density;
struct {
struct {
/* Balsara switch */
float balsara;
/* Balsara switch */
float balsara;
/* Pressure over density squared (including drho/dh term) */
float P_over_rho2;
/* Pressure over density squared (including drho/dh term) */
float P_over_rho2;
/* Particle sound speed. */
float soundspeed;
/* Particle sound speed. */
float soundspeed;
/* Signal velocity. */
float v_sig;
/* Signal velocity. */
float v_sig;
/* Entropy time derivative */
float entropy_dt;
/* Entropy time derivative */
float entropy_dt;
/* Time derivative of the smoothing length */
float h_dt;
/* Time derivative of the smoothing length */
float h_dt;
} force;
};
} force;
// };
/* Particle ID. */
long long id;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment