Skip to contents

read_cestam reads the content of stellar structure files form CESTAM code, and save it to a dataframe.

Usage

read_cestam(strFile)

Arguments

file

ASCII file with a stellar structure compliant with stellar oscillations computation with extension .osc or .OSC.

Value

A dataframe with the stellar structure, in which global parameters -common values for the star - are saved as attributes, and variables - physical quantities that vary with the stellar depth- are saved as columns.

Details

This function takes one argument: the stellar structure file .osc from CESTAM code. It should also compatible with last versions (deprecated) of CESAM2K models as well as MESA (OSC-type) models. The input file can be local or web address (http).

Metadata

namename of the model file
codegenerator code name
versionversion of the code
datedate of the computation
timetime of the computation

Global variables

rmassmass, cgs
Rradius, cgs
rphotphotometric radius, cgs
rlumluminosity, cgs, log10
alconvective alpha (dimensionless)
ageage, Myr
rotiniinitial angular rotation (in rad/s)
rloggsurface gravity, cgs, log10
teffeffective temperature (temp(r=rphot)), K
nshellnumber of shells of the model (radial)

Structure variables

rradius profile, cgs, log
qmass profile, cgs, log
temptemperature profile, K
ppressure profile, cgs
rhodensity profile rho, cgs
gammagamma1 parameter, cgs
aastA constant (BV)
rrradius normalized to total radius
c1solar dynamical time
cs2sound speed squared, cgs
vgsolar dynamical time
rotrotation profile, rad/s

See also

read_gong

Examples

mystruc <- read_cestam("/my/path/file.osc")
#> Warning: cannot open file '/my/path/file.osc': No such file or directory
#> Error in file(description = strFile, open = "r"): cannot open the connection

mystruc_from_web <- read_cestam("http://my-path-to-file/myoscfile.osc")
#> Warning: URL 'http://my-path-to-file/myoscfile.osc': status was 'Couldn't resolve host name'
#> Error in file(description = strFile, open = "r"): cannot open the connection to 'http://my-path-to-file/myoscfile.osc'

if (FALSE) {
  mystruc <- read_cestam("/my/path/file.osc")
}