Version 18 (modified by 7 years ago) ( diff ) | ,
---|
3/15/18
Have a working 2D solution on the grid —
As shown in Figure 1, Astrobear interpolates the progenitor density profile (red diamonds, Fig. 1) onto arbitrary positions of the mesh (i.e. cell centers, blue curve).
Figure 1. A comparison of the interpolated density profile from the HSE self gravity module in Astrobear (blue) to the supplied progenitor density profile (red).
After feeding the progenitor density profile through the HSE numerical integrator (to compute an HSE pressure profile for supplied density profile and external pressure), AstroBEAR interpolates the calculated HSE pressure profile onto the grid (Fig. 2). The values of the ambient medium are just the constant progenitor profiles beyond a radius containing 3 solar masses (
).
Figure 2. A comparison of the interpolated pressure profile from HSE self gravity module in Astrobear (blue) to the supplied progenitor pressure profile.
Note, Astrobear’s output doesn't line up exactly with the input progenitor profiles towards the center of the core. I suspect this has to do with interpolation — for instance, the average density calculated for the cell centers should be resolution dependant (to maintain a constant enclosed mass irrespective of resolution), which would move the density profiles away from each other in Fig. 1.
Figures 3 & 4 are zoom-ins of the density and pressure profiles between the innermost zone (located at dx=5.6e+7 cm) and the radius at which the profiles begin to noticeably deviate. Note the progenitor profile has data sampling down to radius of r=7.84e+5 cm, so about 2 orders of magnitude finer resolution than in this example simulation.
Figure 3. Zoom-in of density profiles described in text.
Figure 4. Zoom-in of pressure profiles described in text.
In addition to the given input progenitor profile (red curve) and the lineout from the simulation (blue curve), I’ve plotted two additional profiles in these figures. The first is the initial profile 'object' (populated with the progenitor input values, green curve). This is just the input progenitor values after they have been read into a readable format for astrobear’s HSE solver (i.e. a “profile object”).
The second is the profile object after it has been sent through the HSE solver (yellow curve). Note, although it can’t be seen here, the initial and final density profile objects are exactly identical (green and yellow curves) and they perfectly line up with the progenitor density profile, but the green and yellow pressure profiles are marginally different (~<1%) near the center of the core with the green curve being identical to the initial progenitor pressure profile. This is because the HSE solver calculates what the pressure profile should be in HSE, given the input density profile. Since the input and output pressure profiles deviate slightly indicates that the initial progenitor profile wasn’t exactly in HSE (to within numerical uncertainty).
When we are talking overall differences of ~
in the density profile, perhaps this relatively small discrepancy shouldn’t be worried about too much… Although, it is curious. I am going to run a simulation with a finer resolution to compare to these results here.3/5/18
The HSE module takes as input:
-Pout (ambient pressure that the HSE module integrates inward from
-Starting density profile that the HSE module interpolates between and uses when solving the discretized HSE equation in spherical coords
2/26/18
The Lane Emden equation non-dimensionalizes the HSE equation in an attempt to find analytic solutions. However, analytic solutions only exist for certain values of the polytropic index. Thus, if we are looking for numerical solutions, we can instead just start with the equation of HSE in spherical coordinates and discretize it:
The order of accuracy of this discretization depends on the way M_enc is calculated (see Jonathans description on the wiki). Since there might be some undesirable error depending on how M_enc is calculated, might be worthwhile to see how Liu’s approximate analytic solution for a gamma=5/3 sphere compares to the numerically integrated solution found by this method.
What this discretization gives us then is (for an arbitrary gamma law EOS), the pressure at each zone of a spherical mass distribution in HSE. However, note this method requires a boundary condition (the starting pressure,
) and the density profile ( ). As written, the algorithm takes the starting pressure to be the external pressure, and using the density profile integrates this equation inwards to the center of the sphere. Eventually then, the inner pressure should match the one from the profiles Chris sent me, if that thing is in or near HSE as he says it is.Note, if we were to chose to integrate in the opposite direction then we would instead have to define a cut-off radius to the integration, which would yield the outer pressure of a sphere in HSE given a particular density profile and specified inner pressure boundary condition.
The algorithm that performs the above described operation in AstroBEAR is called the ‘HSE self-gravity profiles object’. This object interpolates (using cubic spline) the density profile of the polytrope for arbitrary resolution given a finite, discrete set of density profile points. Using this interpolated function, the pressure at each cell center is then calculated using the above function (M_enc is calculated inside this object).
2/7/18
Fryer sent progenitor data. The density, pressure, temperature, and velocity profiles of this progenitor look like:
The goal is to get these profiles initialized on an Eulerian grid in astrobear and to make sure the solution can be numerically stable over multiple dynamical times. The question of stability is interesting and something we will turn to next.
The pressure and density profiles of a polytropic sphere in hydrostatic equilibrium (HSE) are given by the Lane-Emden equation. This equation is derived by combining the equation of HSE with Poisson’s equation for gravity and the pressure/density relationship of a polytrope:
where is the polytropic index. Note the polytropic index is related to the adiabatic index () through the equation:
Exact analytic solutions of the Lane-Emden equation exist only for certain values of . These are:
However, for other values of
the Lane-Emden must be numerically integrated.In astrobear, I have written a solver for
which corresponds to the Isothermal limit ( ). In principle, we would be able to initialize an isothermal sphere on the grid using the inner and outer density of the sphere and its radius, but given the density contrast here is >> than the critical value of 14.1, this sphere would be highly gravitationally unstable — I imagine its evolution would be close to that of the singular isothermal sphere.Thus, we need an alternative solution to modeling the progenitor.
I could easily modify the algorithm I have for setting up a polytropic sphere in HSE for
(which corresponds to an adiabatic sphere of ). This would add a new approximate analytic solution to the module for this new value of . However, first will explore using the code's prebuilt routines for numerically integrating the equation of HSE.2/5/18
We would like to model the progenitor of a core collapse supernova in astrobear. The project will be a parameter study to explore the role of magnetic fields and turbulent perturbations on the collapsing core.
Attachments (25)
- progenitor_profiles.png (241.6 KB ) - added by 7 years ago.
- press_2D_lowres.png (203.3 KB ) - added by 7 years ago.
- rho_2D_lowres.png (215.5 KB ) - added by 7 years ago.
- 2D_rho_zoomin.png (244.0 KB ) - added by 7 years ago.
- 2D_press_zoomin.png (232.1 KB ) - added by 7 years ago.
- Screen Shot 2018-03-01 at 9.50.04 AM.png (44.8 KB ) - added by 7 years ago.
- problem.f90_mar15 (5.9 KB ) - added by 7 years ago.
- profile.out_mar15 (40.6 KB ) - added by 7 years ago.
- global.data_mar15 (7.9 KB ) - added by 7 years ago.
- profile_init.out_mar15 (40.6 KB ) - added by 7 years ago.
- progenitor_profiles.dat_mar15 (16.1 KB ) - added by 7 years ago.
- scales.data_mar15 (619 bytes ) - added by 7 years ago.
- physics.data_mar15 (9.8 KB ) - added by 7 years ago.
- problem.data_mar15 (207 bytes ) - added by 7 years ago.
- density_2D_higheres.png (192.8 KB ) - added by 7 years ago.
- density_2D_higheres_zoomin.png (177.4 KB ) - added by 7 years ago.
- highres_2D_tempColor.png (401.0 KB ) - added by 7 years ago.
- highres_2D_rhoColor.png (308.3 KB ) - added by 7 years ago.
- highres_2D_pressColor.png (291.7 KB ) - added by 7 years ago.
- mesh_octant_2tff.png (419.9 KB ) - added by 7 years ago.
- HSE_octant_2tffs.gif (2.4 MB ) - added by 7 years ago.
- vzmach_octant_2tffs.gif (2.2 MB ) - added by 7 years ago.
- rho_octant_2tffs.gif (2.3 MB ) - added by 7 years ago.
- press_octant_2tffs.gif (2.3 MB ) - added by 7 years ago.
- HSE_octant_resolutionStudy.png (64.2 KB ) - added by 7 years ago.