Skip to content

Remove self-species collisions from updates#968

Closed
Maxwell-Rosen wants to merge 1 commit intomainfrom
remove-self-species-collisions
Closed

Remove self-species collisions from updates#968
Maxwell-Rosen wants to merge 1 commit intomainfrom
remove-self-species-collisions

Conversation

@Maxwell-Rosen
Copy link
Copy Markdown
Collaborator

Responding to #967, I'm adding an option to remove species collisions from the dfdt update and CFL calculation.

The large number of lines changed is because this function was wrapped in a giant if statement, which is a fail condition and can be refactored to the top of the file, reducing the layering and indenting.

To condense the changes, the meaningful thing that this flag does is set

  if (lbo->do_not_add_to_dfdt) {
    lbo->rhs_func = gklbo_rhs_disabled;
  }

Disabling the RHS still means the cross moments are computed, but gkyl_dg_updater_lbo_gyrokinetic_advance is not called to advance the CFL rate. We still want to call gkyl_prim_lbo_cross_calc_advance because this is the object that evaluates the moments used for cross-species collisions, which we need for other species.

…control collision updates.

Remove nested if statements for readability.
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.

1 participant