.. _tetrahedron:

tetrahedron
=======================================================

Regular tetrahedron

=========== ===================================== ============ =============
Parameter   Description                           Units        Default value
=========== ===================================== ============ =============
scale       Scale factor or Volume fraction       None                     1
background  Source background                     |cm^-1|              0.001
sld         tetrahedron scattering length density |1e-6Ang^-2|           126
sld_solvent Solvent scattering length density     |1e-6Ang^-2|           9.4
radius      Circumradius                          |Ang|                  100
=========== ===================================== ============ =============

The returned value is scaled to units of |cm^-1| |sr^-1|, absolute scale.


This model provides the form factor for regular tetrahedrons.
Orientation averaging is done by using the Fibonacci quadrature.
This quadrature provides a quasi-uniform distribution of points on the unit sphere
using the golden ratio. The number of points to generate on the unit sphere
is set to 500 points, it usually provides a good balance between accuracy
and computational efficiency.

**Definition**

This model computes the form factor of a regular tetrahedron by defining its size through its circumradius :math:`R`
(parameter called *radius* in the model), which is the radius of the circumscribed sphere. 
The relationship between the circumradius and the edge length is also implemented. The edge length :math:`L`
and volume :math:`V` are given by:

.. math::

    L = \frac{4}{\sqrt{6}} \, R

.. math::

    V = \frac{\sqrt{2}}{12} \, L^3

.. figure:: img/tetrahedron.png

    Regular tetrahedron in its reference orientation.

The four vertices of the tetrahedron, with :math:`\mathbf{v}_0` at the origin,
are defined as:

.. math::

    \mathbf{v}_0 = (0,\ 0,\ 0)

.. math::

    \mathbf{v}_1 =  (\frac{L}{\sqrt{2}},\ \frac{L}{\sqrt{2}},\ 0)

.. math::

    \mathbf{v}_2 = (0,\ \frac{L}{\sqrt{2}},\frac{L}{\sqrt{2}})

.. math::

    \mathbf{v}_3 = (\frac{L}{\sqrt{2}},\ 0,\frac{L}{\sqrt{2}})

The form factor amplitude of a regular tetrahedron is derived using the
projection method described by Yang and al. [4]. The tetrahedron
is defined by four vertices
:math:`(\mathbf{v}_0, \mathbf{v}_1, \mathbf{v}_2, \mathbf{v}_3)`,
where :math:`\mathbf{v}_0` is placed at the origin and serves
as the projection origin. The three remaining vertices are specified such
that the normal vector of each face points away from the tetrahedron.
The form factor amplitude is defined as the Fourier transform of the
particle shape:

.. math::

    F(\mathbf{q}) = \int_V \exp(i\mathbf{q} \cdot \mathbf{r}) \, d\mathbf{r}

The transformation matrix :math:`\mathbf{T}` is built from the three edge
vectors originating at :math:`\mathbf{v}_0`, with each vector forming one
column:

.. math::

    \mathbf{T} = \bigl[\, \mathbf{v}_1 \mid \mathbf{v}_2 \mid \mathbf{v}_3 \,\bigr]

where :math:`(x_i, y_i, z_i)` are the coordinates of vertex :math:`\mathbf{v}_i`.
Introducing the shorthand notation :math:`Q_i = \mathbf{q} \cdot \mathbf{v}_i`, the
general tetrahedral form factor is given by:

.. math::

    F_\mathrm{tetra}(\mathbf{q}) = |\det(\mathbf{T})| \left\{
        \frac{i}{Q_1 (Q_1 - Q_2)(Q_1 - Q_3)} \exp(i Q_1)
      + \frac{i}{Q_2 (Q_2 - Q_1)(Q_2 - Q_3)} \exp(i Q_2) \\
      + \frac{i}{Q_3 (Q_3 - Q_2)(Q_3 - Q_1)} \exp(i Q_3)
      - \frac{i}{Q_1 Q_2 Q_3}
    \right\}

This expression presents numerical singularities in four distinct cases, each handled
analytically.

**Case 1** — :math:`\mathbf{q}` perpendicular to vertex :math:`\mathbf{v}_i`
(:math:`Q_i = 0`, with :math:`Q_j, Q_k \neq 0` and :math:`Q_j \neq Q_k`):

.. math::

    F_P(\mathbf{q}) = |\det(\mathbf{T})| \left\{
        \frac{i}{Q_j^2 (Q_j - Q_k)} \exp(i Q_j)
      + \frac{i}{Q_k^2 (Q_k - Q_j)} \exp(i Q_k)
      + \frac{i(Q_j + Q_k + i Q_j Q_k)}{Q_j^2 \, Q_k^2}
    \right\}

**Case 2** — :math:`\mathbf{q}` perpendicular to edge :math:`\mathbf{v}_i \mathbf{v}_j`
(:math:`Q_i = Q_j`, with :math:`Q_k \neq Q_i`):

.. math::

    F_E(\mathbf{q}) = |\det(\mathbf{T})| \left\{
        \frac{i}{Q_k (Q_k - Q_i)^2} \exp(i Q_k)
      + \frac{i Q_k - 2i Q_i - Q_i^2 + Q_i Q_k}{Q_i^2 (Q_k - Q_i)^2} \exp(i Q_i)
      - \frac{i}{Q_i^2 \, Q_k}
    \right\}

**Case 3** — :math:`\mathbf{q}` perpendicular to a face
(:math:`Q_i = Q_j = Q_k  \neq 0`):

.. math::

    F_F(\mathbf{q}) = |\det(\mathbf{T})| \left\{
        \frac{-i}{Q_i^3}
      + \frac{2i + 2Q_i - i Q_i^2}{2 Q_i^3} \exp(i Q_i)
    \right\}

The formula can be expressed by three alternatives
(i.e. :math:`Q_i = q · v_1` or :math:`Q_i = q · v_2`  or :math:`Q_i = q · v_3` ).

**Case 4** — :math:`\mathbf{q} \to 0` (first-order Taylor expansion):

.. math::

    F_V(\mathbf{q}) = V_\mathrm{tetra}
      + |\det(\mathbf{T})| \, \frac{i(Q_1 + Q_2 + Q_3)}{24}

where the tetrahedral volume is :math:`V_\mathrm{tetra} = |\det(\mathbf{T})| / 6`.

Orientation average: The 1D form factor corresponds to the orientation
average with all the possible orientations having the same probability.
Instead of rotating the shape through all the possible orientations,
it is equivalent to integrate the 3D scattering vector over a sphere
of radius q with the shape in its reference orientation.

The sphere is sampled using Fibonacci quadrature to provide a quasi-uniform
distribution of points on the unit sphere.
The distribution of the N points is computed using the golden ratio
(see fibonacci.py). Each point of the quadrature on the unit sphere
corresponds to a vector :math:`\mathbf{u}_{j}`. In the sum,
all weights :math:`w_j` are taken identical and equal to :math:`\frac{1}{N}`.

.. math::

    P(q) =  \sum_{j=1}^{N} w_j I(q\mathbf{u}_{j}, R)

.. figure:: img/fibonacci_sphere.png

    Fibonacci sphere using N=5810 points.

And the 1D scattering intensity is calculated as:

.. math::

    I(q) = \text{scale} \times V \times (\rho_\text{p} -
    \rho_\text{solvent})^2 \times P(q)

where V is the volume of the tetrahedron, ρ
is the scattering length inside the volume, ρ *solvent*
is the scattering length of the solvent, and (if the data are in absolute
units) *scale* represents the volume fraction (which is unitless).

**Validation**

The model has been tested against experimental data obtained on gold
tetrahedrons at synchrotron Soleil.
Moreover, comparisons with Debye formula calculations were made using
DebyeCalculator library (https://github.com/FrederikLizakJohansen/DebyeCalculator).
Good agreement was found at q < 1 1/Å.


.. figure:: img/tetrahedron_autogenfig.png

    1D plot corresponding to the default parameters of the model.


**Source**

:download:`tetrahedron.py <src/tetrahedron.py>`

**References**

1. Patterson, A. L. (1939). The Diffraction of X-Rays by Small Crystalline Particles.
   *Physical Review*, 56(10), 972‑977. https://doi.org/10.1103/physrev.56.972

2. Li, X., Shew, C., He, L., Meilleur, F., Myles, D. A. A., Liu, E., Zhang, Y., Smith, G. S.,
   Herwig, K. W., Pynn, R., & Chen, W. (2011). Scattering functions of Platonic solids.
   *Journal Of Applied Crystallography*, 44(3), 545‑557. https://doi.org/10.1107/s0021889811011691

3. Croset, B. (2017). Form factor of any polyhedron : a general compact formula and its singularities.
   *Journal Of Applied Crystallography*, 50(5), 1245‑1255. https://doi.org/10.1107/s1600576717010147

4. Yang, T., Chen, X., Zhang, J., Ma, J., & Liu, S. (2023).
   Form factor of any polyhedron and its singularities derived from a projection method.
   *Journal of Applied Crystallography*, 56(1), 167–177. https://doi.org/10.1107/s160057672201130x


**Authorship and Verification**

* **Authors:** Chi-Huan Tung (tungc@ornl.gov)
             Marianne Imperor-Clerc (marianne.imperor@cnrs.fr)
             Sara Mokhtari (smokhtari@insa-toulouse.fr)

* **Last Modified by:** SM **Date:** 17 April 2026

* **Last Reviewed by:** MIC **Date:** 15 April 2026


