Skip to content

Commit

Permalink
Merge branch 'development' into sdc_newton_robustness
Browse files Browse the repository at this point in the history
  • Loading branch information
zingale authored Oct 5, 2023
2 parents 4561f85 + 2c65efc commit 1bba5fa
Show file tree
Hide file tree
Showing 27 changed files with 4,364 additions and 354 deletions.
21 changes: 20 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
# 23.10

* True-SDC no longer evolves density as part of the reaction system
and now uses the same ODE code path as simplified-SDC. This means
we don't need our own custom VODE righthand side functions (#2559,
#2560, #2567, #2578, #2580, #2584)

* The true SDC runtime parameter `sdc_solve_for_rhoe` has been
removed. (#2572)

* The true SDC runtime parameters `sdc_solver_tol_spec`,
`sdc_solver_tol_ener`, `sdc_solver_atol` have been removed.
Instead the Microphysics integration tolerance parameters should
be used. (#2571)

* The true SDC runtime parameter `sdc_newton_use_analytic_jac` has
been removed. Instead the Microphysics integrator `jacobian`
parameter should be used (#2573)

# 23.08

* Time evolution without subcycling on the fine levels, which is enabled via
Expand Down Expand Up @@ -29,7 +48,7 @@
# 23.06

* The job_info file now reports the integrator used (#2463)

* 1-d cylindrical geometry was fixed (#2465, #2470)

# 23.05
Expand Down
4 changes: 3 additions & 1 deletion Docs/source/AMR.rst
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,8 @@ fine cell data above it.)

The synchronization consists of two parts:

.. index:: castro.do_reflux

- Step 1: Hyperbolic reflux

In the hyperbolic reflux step, we update the conserved variables with
Expand All @@ -159,7 +161,7 @@ The synchronization consists of two parts:
where :math:`V` is the volume of the cell and the correction from
:math:`\delta\Fb` is supported only on coarse cells adjacent to fine grids.

Note: this can be enabled/disabled via castro.do_reflux. Generally,
Note: this can be enabled/disabled via ``castro.do_reflux``. Generally,
it should be enabled (1).

Also note that for axisymmetric or 1D spherical coordinates, the
Expand Down
26 changes: 16 additions & 10 deletions Docs/source/FlowChart.rst
Original file line number Diff line number Diff line change
Expand Up @@ -662,12 +662,13 @@ The overall evolution appears as:

#. *Initialization* (``initialize_advance``)

Here we create the ``MultiFab`` s that store the needed information
We first do a ``clean_state`` on the old data (``S_old``).

We next create the ``MultiFab`` s that store the needed information
at the different time nodes. Each of the quantities below is a
vector of size ``SDC_NODES``, whose components are the ``MultiFab``
for that time node:


* ``k_new`` : the current solution at this time node.

Note that
Expand Down Expand Up @@ -700,14 +701,15 @@ SDC Single Iteration Flowchart

.. index:: do_advance_sdc

The update through all time nodes for a single iteration is done by
``do_advance_sdc``. The basic update appears as:

Throughout this driver we use the ``State_Type`` ``StateData`` as
storage for the current node. In particular, we use the new time slot
in the ``StateData`` (which we refer to as ``S_new``) to allow us to
do ``FillPatch`` operations.

The update through all time nodes for a single iteration is done by
``do_advance_sdc``. The basic update appears as:


#. *Initialize*

We allocate ``Sborder``. Just like with the Strang CTU driver, we
Expand Down Expand Up @@ -756,18 +758,18 @@ do ``FillPatch`` operations.

Then fill all other time nodes as: ``R_old[n]`` = ``R_old[0]``

* Do the SDC update from node ``m`` to ``m+1``.
* Do the SDC update from node ``m`` to ``m+1``.

We call ``do_sdc_update()`` to do the update in time to the next
node. This solves the nonlinear system (when we have reactions)
and stores the solution in ``k_new[m+1]``.
We call ``do_sdc_update()`` to do the update in time to the next
node. This solves the nonlinear system (when we have reactions)
and stores the solution in ``k_new[m+1]``.

#. Store the advective terms for the next iteration.

Since we are done with this iteration, we do: ``A_old[n]``
:math:`\leftarrow` ``A_new[n]``.

We also store ``R_old`` for the next iteration. We do this by
#. Store ``R_old`` for the next iteration. We do this by
calling the reaction source one last time using the data for each
time node.

Expand All @@ -777,6 +779,10 @@ do ``FillPatch`` operations.

``S_new`` :math:`\leftarrow` ``k_new[SDC_NODES-1]``

#. Store the old and new sources in the State Data.

#. Store the reaction information for the plotfiles.

#. Call ``finalize_do_advance`` to clean up the memory.


Expand Down
10 changes: 7 additions & 3 deletions Docs/source/Hydrodynamics.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1020,9 +1020,13 @@ parameters apply:

- 1: the Colella & Glaz solver

- 2: the HLLC solver. Note: this should only be used with Cartesian
geometries because it relies on the pressure term being part of the flux
in the momentum equation.
- 2: the HLLC solver.

.. note::

HLLC should only be used with Cartesian
geometries because it relies on the pressure term being part of the flux
in the momentum equation.

The default is to use the solver based on an unpublished Colella,
Glaz, & Ferguson manuscript (it also appears in :cite:`pember:1996`),
Expand Down
2 changes: 1 addition & 1 deletion Docs/source/Verification.rst
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ Light Front

The light front problem tests the ability of the radiation solver to
operate in the free-streaming limit. A radiation front is
estabilished by initializing one end of the computational domain with
established by initializing one end of the computational domain with
a finite radiation field, and zero radiation field everywhere else.
The speed of propagation of the radiation front is keep in check by
the flux-limiters, to prevent it from exceeding :math:`c`.
Expand Down
2 changes: 1 addition & 1 deletion Docs/source/software.rst
Original file line number Diff line number Diff line change
Expand Up @@ -622,7 +622,7 @@ get a sense of these is to look at the ``.H`` files in the
------------------

There is a ``Geometry`` object, ``geom`` for each level as part of
the ``Castro`` object (this is inhereted through ``AmrLevel``).
the ``Castro`` object (this is inherited through ``AmrLevel``).

``ParmParse`` class
-------------------
Expand Down
50 changes: 25 additions & 25 deletions Exec/radiation_tests/Rad2Tshock/ci-benchmarks/Rad2TShock-1d.out
Original file line number Diff line number Diff line change
@@ -1,40 +1,40 @@
plotfile = plt_00025
time = 0.00026084061812361401
time = 0.00026083835470476599
variables minimum value maximum value
density 5.4596904436e-13 1.2717694091e-12
xmom 1.2328047524e-07 1.4591226172e-07
density 5.4596904436e-13 1.2720098871e-12
xmom 1.2327065163e-07 1.4587103381e-07
ymom 0 0
zmom 0 0
rho_E 0.021940622285 0.039194728059
rho_e 0.0068091599514 0.032333527949
Temp 100.00003115 217.29660609
rho_X 5.4596904436e-13 1.2717694091e-12
rad 7.5662675907e-07 1.4083418723e-05
pressure 0.0045394399678 0.0215556853
kineng 0.0064473434191 0.015131462334
soundspeed 117717.62829 173527.33922
rho_E 0.021940622286 0.039199658391
rho_e 0.0068091599527 0.032333529333
Temp 100.00003116 217.3564598
rho_X 5.4596904436e-13 1.2720098871e-12
rad 7.5662679486e-07 1.4083425328e-05
pressure 0.0045394399687 0.021555686223
kineng 0.0064467244856 0.015131462333
soundspeed 117717.6283 173551.23637
Gamma_1 1.6666666667 1.6666666667
MachNumber 0.6068973935 1.9999997207
uplusc 269518.17809 362247.33487
uminusc -66804.446805 117717.59541
entropy 2458725989.8 2507184972.2
MachNumber 0.60689740202 1.9999997205
uplusc 269483.97988 362284.15407
uminusc -66810.704217 117717.5954
entropy 2458725989.8 2507243428
magvort 0 0
divu -20283.836079 245.94831837
eint_E 12471696009 27100563708
eint_e 12471696009 27100563708
logden -12.26283198 -11.895591626
StateErr_0 5.4596904436e-13 1.2717694091e-12
StateErr_1 100.00003115 217.29660609
divu -20286.061564 245.50876324
eint_E 12471696011 27108028479
eint_e 12471696011 27108028479
logden -12.26283198 -11.895509513
StateErr_0 5.4596904436e-13 1.2720098871e-12
StateErr_1 100.00003116 217.3564598
StateErr_2 1 1
X(X) 1 1
abar 1 1
x_velocity 102299.57948 235435.22371
x_velocity 102258.95554 235435.2237
y_velocity 0 0
z_velocity 0 0
magvel 102299.57948 235435.22371
radvel -235435.22371 114042.93363
magvel 102258.95554 235435.2237
radvel -235435.2237 114038.34336
circvel 0 0.005524271728
magmom 1.2328047524e-07 1.4591226172e-07
magmom 1.2327065163e-07 1.4587103381e-07
angular_momentum_x 0 0
angular_momentum_y 0 0
angular_momentum_z 0 0
Expand Down
130 changes: 65 additions & 65 deletions Exec/science/Detonation/ci-benchmarks/sdc_det_plt00040_extrema.out
Original file line number Diff line number Diff line change
@@ -1,79 +1,79 @@
plotfile = det_x_plt00040
time = 5.1558159137010903e-06
variables minimum value maximum value
density 185259703.62 216632855.61
xmom -73614997193 2.950511888e+16
density 185260168 216581718.87
xmom -65665876144 2.9498376337e+16
ymom 0 0
zmom 0 0
rho_E 1.3062473822e+26 2.789305721e+26
rho_e 1.3062473822e+26 2.7750368401e+26
Temp 50000002.242 7845855083.7
rho_H1 2.1206512613e-22 0.020000133523
rho_He3 0.0017224949189 0.021023375462
rho_He4 94357639.072 200001777.65
rho_C12 0.020000000214 21232035.46
rho_N14 1.9999997735e-22 1309.9957212
rho_O16 0.019999999998 19209.484633
rho_Ne20 0.019999999998 15403.34656
rho_Mg24 0.019999999998 23316.245425
rho_Si28 0.019999999998 2015224.2113
rho_S32 0.019999999998 1656287.9261
rho_Ar36 0.019999999998 821891.34664
rho_Ca40 0.019999999998 725035.59799
rho_Ti44 0.019999999998 34177.948134
rho_Cr48 0.019999999998 78136.778748
rho_Fe52 0.019999999998 278009.71311
rho_Fe54 0.019999999998 95011242.573
rho_Ni56 0.019999999998 2237420.8112
rho_n 2.1206512613e-22 234580.45592
rho_p 0.019999995436 3609780.2473
rho_enuc -4.6854492557e+29 3.5779455282e+32
pressure 5.5236728662e+25 1.1610551634e+26
kineng 0 2.0451461945e+24
soundspeed 612864631.28 895226108.54
Gamma_1 1.3599756153 1.3820354139
MachNumber 0 0.16107073838
uplusc 612864631.28 999603676.63
uminusc -895226447.4 -612860134.18
entropy 98214769.614 336273476.62
rho_E 1.3062473822e+26 2.7889587452e+26
rho_e 1.3062473822e+26 2.7747032576e+26
Temp 50000002.242 7845854636.1
rho_H1 2.1207474382e-22 0.020000122856
rho_He3 0.0017224302211 0.021022965925
rho_He4 94383054.619 200001670.89
rho_C12 0.020000000214 21356780.225
rho_N14 1.9999989146e-22 0.020000168049
rho_O16 0.019999999998 19209.480543
rho_Ne20 0.019999999998 13162.840422
rho_Mg24 0.019999999998 23319.285605
rho_Si28 0.019999999998 2015271.217
rho_S32 0.019999999998 1656229.9122
rho_Ar36 0.019999999998 821818.64951
rho_Ca40 0.019999999998 725327.27962
rho_Ti44 0.019999999998 34171.893679
rho_Cr48 0.019999999998 78189.409032
rho_Fe52 0.019999999998 278027.80691
rho_Fe54 0.019999999998 95004483.767
rho_Ni56 0.019999999998 2238843.5743
rho_n 2.1207474382e-22 234580.14578
rho_p 0.019999995436 3609938.2338
rho_enuc -4.6757680073e+29 3.5780501818e+32
pressure 5.5236728662e+25 1.1610545851e+26
kineng 0 2.0436963139e+24
soundspeed 612864631.28 895226072.17
Gamma_1 1.3599756231 1.3820776319
MachNumber 0 0.16098334941
uplusc 612864631.28 999588584.12
uminusc -895226385.45 -612860404.21
entropy 98214769.614 336273430.26
magvort 0 0
divu -97913.435105 33932.952247
eint_E 6.5312369112e+17 1.3804344965e+18
eint_e 6.5312369112e+17 1.3804344965e+18
logden 8.2677809649 8.3357243245
StateErr_0 185259703.62 216632855.61
StateErr_1 50000002.242 7845855083.7
divu -97898.205698 33936.615428
eint_E 6.5312369112e+17 1.3804343907e+18
eint_e 6.5312369112e+17 1.3804343907e+18
logden 8.2677820536 8.3356217961
StateErr_0 185260168 216581718.87
StateErr_1 50000002.242 7845854636.1
StateErr_2 1e-30 9.9999779314e-11
X(H1) 1e-30 9.9999779314e-11
X(He3) 8.9854753938e-12 9.9999601244e-11
X(He4) 0.48402991788 0.9999999982
X(C12) 1.0000000107e-10 0.10012035382
X(N14) 1e-30 6.1773274327e-06
X(O16) 9.999999999e-11 9.6047421179e-05
X(Ne20) 9.999999999e-11 7.2634981719e-05
X(Mg24) 9.999999999e-11 0.00011116058012
X(Si28) 9.999999999e-11 0.010055718145
X(S32) 9.999999999e-11 0.0083470010273
X(Ar36) 9.999999999e-11 0.004165653613
X(Ca40) 9.999999999e-11 0.0037097977227
X(Ti44) 9.999999999e-11 0.00017298351185
X(Cr48) 9.999999999e-11 0.00040082116268
X(Fe52) 9.999999999e-11 0.0013384275423
X(Fe54) 9.999999999e-11 0.4649087176
X(Ni56) 9.999999999e-11 0.010328169312
X(n) 1e-30 0.0011729013039
X(p) 9.9999977059e-11 0.017597003408
abar 4.000000001 6.7314197717
Ye 0.49998669277 0.50001557826
x_velocity -368.07483814 138629924.04
X(He3) 8.9861891466e-12 9.9999601244e-11
X(He4) 0.48404046077 0.9999999982
X(C12) 1.0000000107e-10 0.10070402463
X(N14) 1e-30 1.0000000461e-10
X(O16) 9.999999999e-11 9.6047399871e-05
X(Ne20) 9.999999999e-11 6.2066987254e-05
X(Mg24) 9.999999999e-11 0.00011117102392
X(Si28) 9.999999999e-11 0.010061112286
X(S32) 9.999999999e-11 0.0083507383612
X(Ar36) 9.999999999e-11 0.0041671868568
X(Ca40) 9.999999999e-11 0.0037113184679
X(Ti44) 9.999999999e-11 0.00017306364204
X(Cr48) 9.999999999e-11 0.00040099187008
X(Fe52) 9.999999999e-11 0.0013389369622
X(Fe54) 9.999999999e-11 0.46488111991
X(Ni56) 9.999999999e-11 0.010337177053
X(n) 1e-30 0.0011729003504
X(p) 9.9999977036e-11 0.017600501144
abar 4.000000001 6.7311470542
Ye 0.49998666383 0.5000155877
x_velocity -328.32930659 138563308.75
y_velocity 0 0
z_velocity 0 0
t_sound_t_enuc 3.441191753e-13 0.97463512872
enuc -2.4912109618e+21 1.6516172111e+24
magvel 0 138629924.04
radvel -368.07483814 138629924.04
t_sound_t_enuc 3.4411947755e-13 0.97502907407
enuc -2.4860875728e+21 1.6520554923e+24
magvel 0 138563308.75
radvel -328.32930659 138563308.75
circvel 0 2
magmom 0 2.950511888e+16
magmom 0 2.9498376337e+16
angular_momentum_x 0 0
angular_momentum_y 0 0
angular_momentum_z 0 0
Expand Down
Loading

0 comments on commit 1bba5fa

Please sign in to comment.