Function write_single_particle

pub fn write_single_particle(weight_window: &WeightWindow, output: &str)
Expand description

Convenience function for writing a WeightWindow into a single wwout file

A WeightWindow instance corresponds to a full set of weight windows for a single particle type.

These can be combined into a multi-particle wwout using the write_multi_particle() function.

let mut ww_set = WeightWindow {
    weights: vec![0.2, 0.15, 0.4],
    ..Default::default()
};

// Write to file
write_single_particle(&ww_set, "wwout");