jax_md_mod.custom_quantity.init_rdf

Contents

jax_md_mod.custom_quantity.init_rdf#

init_rdf(displacement_fn, rdf_params, reference_box=None, rdf_species=None)[source]#

Initializes a function that computes the radial distribution function (RDF) for a single state.

Parameters:
  • displacement_fn – Displacement function

  • rdf_params – RDFParams defining the hyperparameters of the RDF

  • reference_box – Simulation box. Can be provided here for constant boxes or on-the-fly as kwarg ‘box’, e.g. for NPT ensemble

  • rdf_species – Array of species pairs for which the RDF should be computed. If not provided, compute the RDF for all particles irrespectively of their species.

Returns:

A function taking a simulation state and returning the instantaneous RDF