################################
@{{ program }}@ - RETIS analysis
################################

RETIS analysis report generated by @{{ program }}@ version @{{ version }}@
on @{{ date }}@.

The main results are:

* The crossing probability:
  :math:`P_{\text{cross}} = @{{ numbers['pcross'] }}@  \pm  @{{ numbers['perr'] }}@ \%`

* The initial flux (unit: 1/@{{ text['flux-unit'] }}@):
  :math:`f_{A} = @{{ numbers['flux'] }}@  \pm  @{{ numbers['flux-err'] }}@ \%`

* The rate constant (unit: 1/@{{ text['flux-unit'] }}@):
  :math:`k_{AB} = @{{ numbers['rate'] }}@  \pm  @{{ numbers['rate-err'] }}@ \%`

@{% if (numbers['permeability'] is defined) and numbers['permeability'] %}@

* Matching factor between the two [0] ensembles:
  :math:`\xi = @{{ numbers['xi'] }}@ \pm @{{ numbers['xi-err'] }}@ \%`

* The time spent in the reference bin (unit: @{{ text['flux-unit'] }}@ / OP-unit):
  :math:`\frac{\tau_{{\mathrm{ref}},[{0^-}{'}]}}{dz} = @{{ numbers['tau'] }}@ \pm @{{ numbers['tau-err'] }}@ \%`

* The permeability (unit: OP-unit/ @{{ text['flux-unit'] }}@ ):
  :math:`P = @{{ numbers['perm'] }}@ \pm @{{ numbers['perm-err'] }}@ \%`


@{% endif %}@

.. _combined-results:

Combined results
================

The overall matched probability distributions are shown in the left figure
while the matched probability distribution is shown in the right figure below.
The overall crossing rate as a function of cycles
and its relative error block analysis are reported in the two following
plots, respectively.

.. image:: @{{ figures['total'] }}@
   :width: 45%
.. image:: @{{ figures['matched']}}@
   :width: 45%
.. image:: @{{ figures['progress'] }}@
   :width: 45%
.. image:: @{{ figures['error']}}@
   :width: 45%

@{% if (numbers['permeability'] is defined) and numbers['permeability'] %}@
Results for [0^-']
====================
@{% endif %}@

@{% if (numbers['permeability'] is defined) and numbers['permeability'] %}@
.. image:: @{{ figures['xi'] }}@
   :width: 30%
.. image:: @{{ figures['xierror'] }}@
   :width: 30%
.. image:: @{{ figures['tau'] }}@
   :width: 30%
.. image:: @{{ figures['tauerror'] }}@
   :width: 30%
.. image:: @{{ figures['tauref'] }}@
   :width: 30%


@{% endif %}@


.. _figure-results:

Results for path ensembles
==========================

The following interfaces were used in the simulation (and analysis)
for calculating the crossing probabilities:

@{{ tables['interfaces'] }}@

@{{ tables['probability'] }}@

@{{ tables['efficiency'] }}@

.. _prob-figures-output:

Crossing probabilities
----------------------

@{% for figure in figures['tis'] %}@
.. image:: @{{ figure['pcross'] }}@
   :width: 30%
.. image:: @{{ figure['prun'] }}@
   :width: 30%
.. image:: @{{ figure['perror'] }}@
   :width: 30%
@{% endfor %}@


.. _len-shoot-figures-output:

Distributions for path lengths and shooting moves
-------------------------------------------------

The average path lengths in the different ensembles are given in
the table below and some distributions for the path lengths and
shooting moves can also be found here:

.. image:: @{{ figures['path0']['lpath'] }}@
   :width: 45%
.. image:: @{{ figures['path0']['shoots'] }}@
   :width: 45%

@{% for figure in figures['tis'] %}@
.. image:: @{{ figure['lpath'] }}@
   :width: 45%
.. image:: @{{ figure['shoots'] }}@
   :width: 45%
@{% endfor %}@

