sarkas.tools.observables.CurrentCorrelationFunction#

class sarkas.tools.observables.CurrentCorrelationFunction[source]#

Current Correlation Functions.

The species dependent longitudinal ccf \(L_{AB}(\mathbf k, \omega)\) is defined as

\[L_{AB}(\mathbf k,\omega) = \int_0^\infty dt \, \left \langle \left [\mathbf k \cdot \mathbf v_{A} ( \mathbf k, t) \right ] \left [ - \mathbf k \cdot \mathbf v_{B} ( -\mathbf k, t) \right \rangle \right ] e^{i \omega t},\]

while the transverse are

\[T_{AB}(\mathbf k,\omega) = \int_0^\infty dt \, \left \langle \left [ \mathbf k \times \mathbf v_{A} ( \mathbf k, t) \right ] \cdot \left [ -\mathbf k \times \mathbf v_{A} ( -\mathbf k, t) \right \rangle \right ] e^{i \omega t},\]

where the microscopic velocity of species \(A\) with number of particles \(N_{A}\) is given by

\[\mathbf v_{A}(\mathbf k,t) = \sum^{N_{A}}_{j} \mathbf v_j(t) e^{-i \mathbf k \cdot \mathbf r_j(t)} .\]
Variables
  • k_list (list) – List of all possible \(k\) vectors with their corresponding magnitudes and indexes.

  • k_counts (numpy.ndarray) – Number of occurrences of each \(k\) magnitude.

  • ka_values (numpy.ndarray) – Magnitude of each allowed \(ka\) vector.

  • no_ka_values (int) – Length of ka_values array.

Methods

CurrentCorrelationFunction.__init__()

CurrentCorrelationFunction.calc_k_data()

Calculate and save Fourier space data.

CurrentCorrelationFunction.calc_kt_data([...])

Calculate Time dependent Fourier space quantities.

CurrentCorrelationFunction.compute()

Calculate the observable (and its autocorrelation function).

CurrentCorrelationFunction.create_dirs_filenames()

CurrentCorrelationFunction.from_dict(input_dict)

Update attributes from input dictionary.

CurrentCorrelationFunction.grab_sim_data([pva])

Read in particles data

CurrentCorrelationFunction.parse()

Grab the pandas dataframe from the saved csv file.

CurrentCorrelationFunction.parse_k_data()

Read in the precomputed Fourier space data.

CurrentCorrelationFunction.parse_kt_data([...])

Read in the precomputed time dependent Fourier space data.

CurrentCorrelationFunction.plot([scaling, ...])

Plot the observable by calling the pandas.DataFrame.plot() function and save the figure.

CurrentCorrelationFunction.pretty_print()

Print current correlation function calculation parameters for help in choice of simulation parameters.

CurrentCorrelationFunction.read_pickle()

Read the observable's info from the pickle file.

CurrentCorrelationFunction.save_hdf()

CurrentCorrelationFunction.save_pickle()

Save the observable's info into a pickle file.

CurrentCorrelationFunction.setup(params[, ...])

Assign attributes from simulation's parameters.

CurrentCorrelationFunction.setup_init(params)

Assign Observables attributes and copy the simulation's parameters.

CurrentCorrelationFunction.setup_multirun_dirs()

Set the attributes postprocessing_dir and dump_dirs_list.

CurrentCorrelationFunction.time_stamp(...)

Print to screen the elapsed time of the calculation.

CurrentCorrelationFunction.update_args(**kwargs)

Update observable specific attributes and call update_finish() to save info.

CurrentCorrelationFunction.update_finish()

Update the slice_steps, CCF's and DSF's attributes, and save pickle file with observable's info.