AMReX-Astro / AMReX-Astro/Castro

switch CTU to conservative diffusion

Open
#495 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

diffusion
Dominant language
C++
Stars
340
Forks
105
Avg merge
3d 8h
Merged PRs (30d)
8

Description

Currently we treat diffusion as an external source and compute the old-time diffusion from S_old, use this in the predictor, and then compute the new-time diffusion after the conservative update, from S_new. The final source is then 1/2(diffusion_old + diffusion_new). However, this is not conservative, and no correction is done at C-F interfaces.

We should instead compute the diffusive flux, -k_th grad T and add this to the energy flux. To be second order, we would still need the old-time diffusion in the predictor to the interface states, and we would also need to evaluate this flux from the Godunov state (including the transport coefficients). This would then automatically be conservative and participate in the flux correction.

This approach will also address #369

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the current CTU diffusion path through S_old, S_new, the predictor, and the conservative update. Review how the Godunov state and transport coefficients produce the energy flux, then verify that the diffusive flux participates in C-F interface correction and that the final update is conservative and second order.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.