# Zfs sampling.m

Gadolinium ZFS probability distribution function for DOTA-type ligand complexes in cryogenic water-methanol glasses.

## Syntax

    [D,E,W]=zfs_sampling(npoints_d,npoints_e,tol)


## Description

This function returns Gauss-Legendre quadrature sampling points and weights for the ZFS parameter distribution described in http://dx.doi.org/10.1007/BF03166762 (see Figure 5). This function is necessary in the simulation of solid state EPR experimens involving gadolinium ions because there is always a distribution of zero-field splitting parameters that must be integrated over.

## Arguments

    npoints_d - number of Gauss-Legendre quadrature points in D

    npoints_e - number of Gauss-Legendre quadrature points in D

    tol       - tolerance for integration weights below which the sampling points are dropped


## Returns

    D - a vector of D/D1 values for each sampling point (see Figure 5 in the paper)

    E - a vector of E/D values for each sampling point (see Figure 5 in the paper)

    W - Gauss-Legendre quadrature weight for each point


## Examples

See the gadolinium DEER simulation examples in the example set and Figure 5 in the paper cited above.

## Notes

1. Distribution parameters are different between ligands. Modify the function as appropriate for your case.