Skip to content

Commit

Permalink
Add asked changes
Browse files Browse the repository at this point in the history
  • Loading branch information
bastiencarreres committed Feb 21, 2024
1 parent 91f8428 commit 3beb6c4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docs/models.rst
Original file line number Diff line number Diff line change
Expand Up @@ -253,13 +253,13 @@ The intrinsic scattering of SNe Ia is color dependant it can be modelled for sim
by G10 or C11 models. The implemention is based on Kessler et al. 2012.
They both act as random variation in the spectra model of a `~sncosmo.SALT2Source` or `~sncosmo.SALT3Source`.

The G10 model take a `SALTSource` as an argument and can be added to your `~sncosmo.Model` as:
The G10 model relies on SALT2 residuals, thus it needs to take a `SALTSource` as an argument. It can be added to your `~sncosmo.Model` as:

.. code:: python
>>> source = 'salt2'
>>> SALTSource = sncosmo.models.get_source(name=source)
>>> G10 = snc.models.G10(SALTsource=SALTSource)
>>> G10 = sncosmo.models.G10(SALTsource=SALTSource)
>>> SALTwithG10 = sncosmo.Model(source='salt2',
effects=[G10],
effect_names=['G10'],
Expand All @@ -270,11 +270,11 @@ The G10 model parameters are:
* ``L0``, ``F0`` and ``F1`` are used in the multiplicative factor introduced in Kessler et al. 2012. Their default values are ``L0=2157.3``, ``F0=0`` and ``F1=1.08e-4``.
* ``dL`` the wavelength range between each scatter node. Following Kessler et al. 2012 it is set by default to 800A.

The C11 model can be added to your `~sncosmo.Model` as:
Since the C11 model does not relies on SALT2 residuals, it does not need a `SALTSource`. It can be added to your `~sncosmo.Model` as:

.. code:: python
>>> C11 = snc.models.C11()
>>> C11 = sncosmo.models.C11()
>>> SALTwithC11 = sncosmo.Model(source='salt2',
effects=[C11],
effect_names=['C11'],
Expand Down Expand Up @@ -414,4 +414,4 @@ parameters:
>>> source = sncosmo.SALT2Source(modeldir='/path/to/dir',
... m0file='mytemplate0file.dat')

See for more details.
See `~sncosmo.SALT2Source` for more details.

0 comments on commit 3beb6c4

Please sign in to comment.