Skip to content
Snippets Groups Projects

Planetary remix hydro

Closed Matthieu Schaller requested to merge planetary_remix_hydro into master

@dc-sand2's work on the new SPH implementation.

Features:

  • xxx
  • yyy
Edited by Matthieu Schaller

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • 19 ******************************************************************************/
    20 #ifndef SWIFT_PLANETARY_HYDRO_IO_H
    21 #define SWIFT_PLANETARY_HYDRO_IO_H
    22
    23 /**
    24 * @file Planetary/hydro_io.h
    25 * @brief Minimal conservative implementation of SPH (i/o routines)
    26 *
    27 * The thermal variable is the internal energy (u). Simple constant
    28 * viscosity term with the Balsara (1995) switch (optional).
    29 * No thermal conduction term is implemented.
    30 *
    31 * This corresponds to equations (43), (44), (45), (101), (103) and (104) with
    32 * \f$\beta=3\f$ and \f$\alpha_u=0\f$ of
    33 * Price, D., Journal of Computational Physics, 2012, Volume 231, Issue 3,
    34 * pp. 759-794.
  • 210 /*! Particle pressure. */
    211 float pressure;
    212
    213 /*! Particle soundspeed. */
    214 float soundspeed;
    215
    216 /*! Particle signal velocity */
    217 float v_sig;
    218
    219 /*! Time derivative of smoothing length */
    220 float h_dt;
    221
    222 /*! Balsara switch */
    223 float balsara;
    224
    225 float eta_crit;
  • 198 198 runner_doself1_branch_density(r, ci);
    199 199 #ifdef EXTRA_HYDRO_LOOP
    200 200 else if (t->subtype == task_subtype_gradient)
    201 runner_doself1_branch_gradient(r, ci);
    201 // runner_doself1_branch_gradient(r, ci);
    202 runner_doself2_branch_gradient(r, ci);
  • 109 A->xz * (A->xx * B->xz + A->xy * B->yz + A->xz * B->zz));
    110 M_out->yy = (A->xy * (A->xy * B->xx + A->yy * B->xy + A->yz * B->xz) +
    111 A->yy * (A->xy * B->xy + A->yy * B->yy + A->yz * B->yz) +
    112 A->yz * (A->xy * B->xz + A->yy * B->yz + A->yz * B->zz));
    113 M_out->zz = (A->xz * (A->xz * B->xx + A->yz * B->xy + A->zz * B->xz) +
    114 A->yz * (A->xz * B->xy + A->yz * B->yy + A->zz * B->yz) +
    115 A->zz * (A->xz * B->xz + A->yz * B->yz + A->zz * B->zz));
    116 M_out->xy = (A->xy * (A->xx * B->xx + A->xy * B->xy + A->xz * B->xz) +
    117 A->yy * (A->xx * B->xy + A->xy * B->yy + A->xz * B->yz) +
    118 A->yz * (A->xx * B->xz + A->xy * B->yz + A->xz * B->zz));
    119 M_out->xz = (A->xz * (A->xx * B->xx + A->xy * B->xy + A->xz * B->xz) +
    120 A->yz * (A->xx * B->xy + A->xy * B->yy + A->xz * B->yz) +
    121 A->zz * (A->xx * B->xz + A->xy * B->yz + A->xz * B->zz));
    122 M_out->yz = (A->xz * (A->xy * B->xx + A->yy * B->xy + A->yz * B->xz) +
    123 A->yz * (A->xy * B->xy + A->yy * B->yy + A->yz * B->yz) +
    124 A->zz * (A->xy * B->xz + A->yy * B->yz + A->yz * B->zz));
  • Matthieu Schaller requested changes

    requested changes

  • added 2 commits

    • 86bb6b30 - Update hydro test initial conditions hdf5 field names
    • a0348107 - Match the planetary-hydro HDF5 field names for initial conditions to the rest...

    Compare with previous version

  • added 1 commit

    • 99b38aba - Update particle quantities and remove unneeded files

    Compare with previous version

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading