Skip to content

Conversation

@nilsdeppe
Copy link
Member

Proposed changes

SpEC has a gradual transition from atmosphere velocities to unlimited velocities. This adds such a gradual change to our atmosphere treatment.

Slightly different restrictions are needed when magnetic fields are present, but that will be added in a followup PR.

Upgrade instructions

Code review checklist

  • The code is documented and the documentation renders correctly. Run
    make doc to generate the documentation locally into BUILD_DIR/docs/html.
    Then open index.html.
  • The code follows the stylistic and code quality guidelines listed in the
    code review guide.
  • The PR lists upgrade instructions and is labeled bugfix or
    major new feature if appropriate.

Further comments

Copy link
Member

@kidder kidder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can squash

@nilsdeppe nilsdeppe force-pushed the improve_atmosphere_treatment branch from 367acfd to 600e5e1 Compare June 9, 2021 15:59
@nilsdeppe
Copy link
Member Author

I've squashed in the change (removed specific enthalpy because its not yet being adjusted), and rebased on develop. Thanks for the review :)

Copy link
Contributor

@fmahebert fmahebert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can squash directly

/// \brief For densities between DensityOfAtmosphere and
/// SmoothTransitionDensityCutoff the velocity is transitioned away from
/// atmosphere to avoid abrupt cutoffs.
struct TransitionDensityCutoff {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Make instances of TransitionDensityCutoff and SmoothTransitionDensityCutoff consistent... I'm not sure which you want but right now you have both...

<< density_of_atmosphere_ << ')');
}
if (transition_density_cutoff_ < density_of_atmosphere_ or
transition_density_cutoff_ > 10.0 * density_of_atmosphere_) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This upper-bound constraint of 10*rho_atmo should be documented in the option struct at least but probably also in the main doxygen for the class

static type lower_bound() noexcept { return 0.0; }
static type upper_bound() noexcept { return 1.0; }
static constexpr Options::String help = {
"The maximum sqrt(v^i v^j gamma_{ij}) allowed."};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would state here also the clause "when the density is below TransitionDensityCutoff"

nilsdeppe added 3 commits June 9, 2021 10:51
We need to also support fixing in strongly magnetized regions. As a first step,
factor out some code so it can be easily reused.
@nilsdeppe nilsdeppe force-pushed the improve_atmosphere_treatment branch from 600e5e1 to 38fe20c Compare June 9, 2021 17:51
@nilsdeppe
Copy link
Member Author

Squashed in the changes. Thanks for the review :)

@nilsdeppe nilsdeppe merged commit 57d6533 into sxs-collaboration:develop Jun 9, 2021
@nilsdeppe nilsdeppe deleted the improve_atmosphere_treatment branch June 9, 2021 23:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants