wiki:HydroStaticStar

Version 11 (modified by idilernia, 12 years ago) ( diff )

HydroStatic Star

Purpose

This module aims to reproduce a situation of hydrostatic equilibrium (HSE), a condition where a volume of a fluid is at rest or at constant velocity. This occurs when compression due to gravity is balanced by a pressure gradient force.

we can translate the image above into the condition:

where dP/dh is the change in pressure with respect to height, ρ is density and g is the gravitational potential.

Implementation

Two fundamental objects are used by this module:

For this module, the first step to recreate the solution is to determine a 1D profile in hydrostatic equilibrium, this profile can then be applied to a spherically symmetric 3D model using interpolation.

With a little bit of imagination we can think of a 1D column of gas as an array of values:

COLUMN TOP
h5ρ5P5
h4ρ4P4
h3ρ3P3
h2ρ2P2
h1ρ1P1
h0ρ0P0
COLUMN BASE

We can relate each level of the column to an position in an array which contains height (h), density(ρ) and pressure(P), that is:

    REAL(KIND=qPREC), DIMENSION(100,3) :: column !where the first indexing is the level 
                                                 !2nd indexing determines the attribute (1 height, 2 rho, 3 pressure)

In this specific implementation, a density profile needs to be specified by the user, the module will be able to calculate the ideal pressure in order to create an HSE solution.

In order to calculate the ideal pressure, we need to interpret:

in a discrete way, this gives:

this simpler form can be applied to our profile array, you can check the Profiles page to see how this is done. After we created this abstraction of a column of gas in hydrostatic equilibrium, we can use interpolation to port this 1D object to a 2D or 3D model.

2D,3D and Softening

Due to steep changes in density and gravitational potential close to the center of mass of a star, the point gravity in this model, some softening of these two parameters is needed.
With PlummerSoftening being used to soften the gravitational potential and force in this module, a difference in the pressure and temperature profile arise between 2D and 3D models.
You can see how the gravity force varies between 2D and 3D:
2D:

GravityForce=-PlummerSoftening2D*mass*ScaleGrav
PlummerSoftening2D=2d0*pos/(sum(pos(1:nDim)**2)+r_soft**2)

3D:

GravityForce=-PlummerSoftening*mass*ScaleGrav
PlummerSoftening=pos/((sum(pos**2)+r_soft**2)**(1.5d0))


Clearly, the 3D model shows a steeper gradient in pressure.
The plot below indicates how the pressure gradient changes between 2D and 3D models and how it has important repercussions on the temperature profile as well.

Refence model comparison and results

We divided the checking of our model accuracy into two stages: 1) comparing module profiles with reference models in the literature 2) running the model

For the first testing stage, the density profile of an AGB star (can be found here) was loaded into the module, after calculating pressure and temperature profiles needed for an HSE condition, the generated profiles were compared with the reference model.
The following plot below compares the two models:

In the second testing stage, the model was run to check for changes in velocity.
Clearly, the outcome that can be expected from an equilibrium condition is the absence of change in velocity. In the case of an equilibrium at rest, we would expect our model not to change over time.
Below is the density, pressure, temperature and mach profiles for our model.

Attachments (4)

Download all attachments as: .zip

Note: See TracWiki for help on using the wiki.