/*! @page pag_concepts_symmetry Symmetry

\section sec_symmetry Symmetry and Domain Averaging

A _symmetry_ under PMSCO is a discrete variant of a set of calculation parameters (including the atomic cluster)
that is derived from the same set of model parameters
and that contributes incoherently to the measured diffraction pattern.
A symmetry may be represented by a special symmetry parameter which is not subject to optimization.

For instance, a real sample may have additional rotational domains that are not present in the cluster,
increasing the symmetry from three-fold to six-fold.
Or, an adsorbate may be present in a number of different lateral configurations on the substrate.
In the first case, it may be sufficient to fold calculated data in the proper way to generate the same symmetry as in the measurement.
In the latter case, it may be necessary to execute a scattering calculation for each possible orientation or a representative number of possible orientations.

PMSCO provides the basic framework to spawn multiple calculations according to the number of symmetries (cf. \ref sec_tasks).
The actual data reduction from multiple symmetries to one measurement needs to be implemented on the project level.
This section explains the necessary steps.

1. Your project needs to populate the pmsco.project.Project.symmetries list.
   For each symmetry, add a dictionary of symmetry parameters,  e.g. <code>{'angle_azi': 15.0}</code>.
   There must be at least one symmetry in a project, otherwise no calculation is executed.

2. The project may apply the symmetry of a task to the cluster and parameter file if necessary.
   The pmsco.project.Project.create_cluster and pmsco.project.Project.create_params methods receive the index of the particular symmetry in addition to the model parameters.

3. The project combines the results of the calculations for the various symmetries into one dataset that can be compared to the measurement.
   The default method implemented in pmsco.project.Project just adds up all calculations with equal weight.
   If you need more control, you need to override the pmsco.project.Project.combine_symmetries method and implement your own algorithm.


*/
