// STRUCTS.H
// Structs used
// © 2021 Peter J. Meyer
struct lattice_type
{
char id[4]; // "SQU", "TRI", etc.
char name[24]; // name of lattice type
int dimensionality; // number of dimensions
int coord_num; // coordination number
double ising_crit_temp; // pure Ising critical temperature
double site_perc_thr; // site percolation threshold
double bond_perc_thr; // bond percolation threshold
};
struct _all_cluster_trace_data
{
// Input:
int cluster_type; // 0 = site, 1 = spin, 2 = Swendsen-Wang virtual spin
int number_clusters; // true = assign numbers to site (or spin) clusters
int stop_on_spanning_cluster; // true = quit when a spanning cluster is found
int get_cluster_size; // true = count cluster size
// Output:
int spanning_cluster_found; // is set to true if spanning cluster found
int num_spanning_clusters;
int num_clusters_traced;
int cluster_number_overflow; // counts number of times cluster number exceeds 65,535.
};
struct _perc_thr_iter
{
int level;
double min_p;
double max_p;
double range; // max_p - min_p
int num_configurations;
double epsilon;
double perc_data[NUM_CONCENTRATIONS][2];
// The first value is a concentration;
// the second is the percentage of spanning clusters at that concentration,
// as determined by generating many site and bond configurations and counting
// how many have a spanning cluster.
int repeat;
int anom_code;
};