Model
- class dustpylib.radtrans.radmc3d.Model(sim, ignore_last=True)[source]
Bases:
objectMain model class that can read in
DustPymodels and can createRADMC-3Dinput files. Attributes with trailing underscore are imported fromDustPy, while the other attributes will be used to createRADMC-3Dinput files.- read_image :
Reads
RADMC-3Dimage file
- read_spectrum :
Reads
RADMC_3dspectrum file
- write_files :
Writes all required
RADMC-3Dinput files into the specified directory
- write_opacity_files :
Writes only the required
RADMC-3Dopacity into files into the specified directory
- Attributes:
ac_gridParticle size bin centers in cm for
RADMC-3Dmodel.ai_gridParticle size bin interfaces in cm for
RADMC-3Dmodelphic_gridAzimuthal grid cell centers in rad for
RADMC-3Dmodel.phii_gridAzimuthal grid cell interfaces in rad for
RADMC-3Dmodel.rc_gridRadial grid cell centers in cm for
RADMC-3Dmodel.ri_gridRadial grid cell interfaces in cm for
RADMC-3Dmodel.thetac_gridPolar grid cell centers in rad for
RADMC-3Dmodel.thetai_gridPolar grid cell interfaces in rad for
RADMC-3Dmodel.
Methods
write_files([datadir, write_opacities, ...])Function writes all required
RADMC-3Dinput files.write_opacity_files([datadir, opacity, ...])Function writes the required opacity files.
Attributes Summary
Particle size bin centers in cm for
RADMC-3Dmodel.Particle size bin interfaces in cm for
RADMC-3DmodelAzimuthal grid cell centers in rad for
RADMC-3Dmodel.Azimuthal grid cell interfaces in rad for
RADMC-3Dmodel.Radial grid cell centers in cm for
RADMC-3Dmodel.Radial grid cell interfaces in cm for
RADMC-3Dmodel.Polar grid cell centers in rad for
RADMC-3Dmodel.Polar grid cell interfaces in rad for
RADMC-3Dmodel.Methods Summary
write_files([datadir, write_opacities, ...])Function writes all required
RADMC-3Dinput files.write_opacity_files([datadir, opacity, ...])Function writes the required opacity files.
Attributes Documentation
- ac_grid
Particle size bin centers in cm for
RADMC-3Dmodel. Do not set manually. Only use size bin interfaces.
- ai_grid
Particle size bin interfaces in cm for
RADMC-3Dmodel
- phic_grid
Azimuthal grid cell centers in rad for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- phii_grid
Azimuthal grid cell interfaces in rad for
RADMC-3Dmodel.
- rc_grid
Radial grid cell centers in cm for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- ri_grid
Radial grid cell interfaces in cm for
RADMC-3Dmodel.
- thetac_grid
Polar grid cell centers in rad for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- thetai_grid
Polar grid cell interfaces in rad for
RADMC-3Dmodel.
Methods Documentation
- write_files(datadir=None, write_opacities=True, opacity=None, smoothing=False)[source]
Function writes all required
RADMC-3Dinput files.- Parameters:
datadir (str, optional, default: None) – Data directory in which the files are written. None defaults to the datadir attribute of the parent class.
write_opacities (booelan, optional, default: True) – If False, does not compute nor write opacity files.
opacity (str, optional, default: None) – Opacity model to be used. Either ‘birnstiel2018’ or ‘ricci2010’. None defaults to ‘birnstiel2018’.
smoothing (bool, optional, default: False) – Smooth the opacities by averaging over multiple particle sizes. This slows down the computation.
- write_opacity_files(datadir=None, opacity=None, smoothing=False)[source]
Function writes the required opacity files.
- Parameters:
datadir (str, optional, default: None) – Data directory in which the files are written. None defaults to the datadir attribute of the parent class.
opacity (str, optional, default: None) – Opacity model to be used. Either ‘birnstiel2018’ or ‘ricci2010’. None defaults to ‘birnstiel2018’.
smoothing (bool, optional, default: False) – Smooth the opacities by averaging over multiple particle sizes. This slows down the computation.
- H_dust_
Dust scale heights array in cm from
DustPy
- M_star_
Stellar mass in g
- R_star_
Stellar radius in cm
- Sigma_dust_
Dust surface density profile in g/cm² from
DustPy
- T_gas_
Temperature profile in K from
DustPy
- T_star_
Stellar effective temperature in K
- a_dust_
Particle size array in cm from
DustPy
- property ac_grid
Particle size bin centers in cm for
RADMC-3Dmodel. Do not set manually. Only use size bin interfaces.
- property ai_grid
Particle size bin interfaces in cm for
RADMC-3Dmodel
- datadir
Directory to store the
RADMC-3D input files
- lam_grid
Wavelength grid for
RADMC-3Din cm
- opacity
Opacity model. “birnstiel2018” (default) or “ricci2010”
- property phic_grid
Azimuthal grid cell centers in rad for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- property phii_grid
Azimuthal grid cell interfaces in rad for
RADMC-3Dmodel.
- radmc3d_options
RADMC-3Doptions for radmc3d.inp file
- property rc_grid
Radial grid cell centers in cm for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- rc_grid_
Radial grid cell centers from
DustPymodel
- property ri_grid
Radial grid cell interfaces in cm for
RADMC-3Dmodel.
- ri_grid_
Radial grid cell interfaces from
DustPymodel
- property thetac_grid
Polar grid cell centers in rad for
RADMC-3Dmodel. Do not set manually. Only use cell interfaces.
- property thetai_grid
Polar grid cell interfaces in rad for
RADMC-3Dmodel.
- write_files(datadir=None, write_opacities=True, opacity=None, smoothing=False)[source]
Function writes all required
RADMC-3Dinput files.- Parameters:
datadir (str, optional, default: None) – Data directory in which the files are written. None defaults to the datadir attribute of the parent class.
write_opacities (booelan, optional, default: True) – If False, does not compute nor write opacity files.
opacity (str, optional, default: None) – Opacity model to be used. Either ‘birnstiel2018’ or ‘ricci2010’. None defaults to ‘birnstiel2018’.
smoothing (bool, optional, default: False) – Smooth the opacities by averaging over multiple particle sizes. This slows down the computation.
- write_opacity_files(datadir=None, opacity=None, smoothing=False)[source]
Function writes the required opacity files.
- Parameters:
datadir (str, optional, default: None) – Data directory in which the files are written. None defaults to the datadir attribute of the parent class.
opacity (str, optional, default: None) – Opacity model to be used. Either ‘birnstiel2018’ or ‘ricci2010’. None defaults to ‘birnstiel2018’.
smoothing (bool, optional, default: False) – Smooth the opacities by averaging over multiple particle sizes. This slows down the computation.