Hybrid Monte Carlo with Fourier Acceleration simulation package for the N=2 Principal Chiral model.
Project description
This python package offers efficient simulation and data analysis routines for the $SU(2) \times SU(2)$ Principal Chiral model. The key feature offered is the integration of Fourier Acceleration into the Hybrid Monte Carlo algorithm which leads to a significant reduction in the degree of critical slowing down.
Currently the simulation is only supported for a two dimensional cubic lattice.
Installation
To install SU2xSU2
using pip
run:
pip install SU2xSU2
Its is recommended to work in a virtual environment. The package comes with a custom style sheet which is used by default.
Documentation
Read the docs here.
Example
A basic example showing how to set up a simulation using Fourier accelerated HMC to measure the wall-to-wall correlation function. Further examples can be found here.
from SU2xSU2.SU2xSU2 import SU2xSU2
# define model and lattice parameters
model_paras = {'L':40, 'a':1, 'ell':5, 'eps':1/5, 'beta':0.6}
model = SU2xSU2(**model_paras)
# define simulation parameters and measurements
sim_paras = {'M':500, 'thin_freq':1, 'burnin_frac':0.5, 'accel':True, 'measurements':[model.ww_correlation_func], 'chain_paths':['corfunc_chain.npy']}
model.run_HMC(**sim_paras)
Licence
SU2xSU2
is free software made available under the MIT License. For details see the LICENSE
file.
To Do
- allow for external measurement functions to be passed. Just need additional argument to run_HMC, specifying the measurement data structure. Add such an example (such as computing kinetic energy per site) to examples.py
- remove thin_freq
- Runtime warning in correlations l.64
- add tests
- generalize simulation and data analysis to d-dimensional cubic lattice
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for SU2xSU2-1.2.5a0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 730cd8a35ed788949f733731dbf0eb2f66ba049a56a4610401d36211e999ec16 |
|
MD5 | f6a5a63392052723f348cb25f9fa2189 |
|
BLAKE2b-256 | c821258d7a45f4988db26250bdaa5617e0c820546ab66efd13260707de924eeb |