Expand description

Combine multiple Monte Carlo methods.

this module present different ways to combine multiple method

Example

use lattice_qcd_rs::simulation::{HeatBathSweep, LatticeState, LatticeStateDefault, OverrelaxationSweepReverse, HybridMethodVec};
use rand::SeedableRng;

let rng = rand::rngs::StdRng::seed_from_u64(0); // change with your seed
let mut heat_bath = HeatBathSweep::new(rng);
let mut overrelax = OverrelaxationSweepReverse::default();
let mut hybrid = HybridMethodVec::with_capacity(2);
hybrid.push_method(&mut heat_bath);
hybrid.push_method(&mut overrelax);

let mut state = LatticeStateDefault::<3>::new_cold(1_f64, 8_f64, 4)?; // 1_f64 : size, 8_f64: beta, 4 number of points.
for _ in 0..2 {
    state = state.monte_carlo_step(&mut hybrid)?;
    // operation to track the progress or the evolution
}
// operation at the end of the simulation

Structs

Enums

Type Definitions