diff options
author | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2018-02-28 20:33:41 -0500 |
---|---|---|
committer | Jaron Kent-Dobias <jaron@kent-dobias.com> | 2018-02-28 20:33:41 -0500 |
commit | 1fbcb4dd4e52daeb53becba33827f8e48c5606b2 (patch) | |
tree | 6b8088fef6ca3e5f11551073b7793f6e9e767670 /lib/wolff.h | |
parent | e0d4943090c285a44dad501cf9dc24714f9b3530 (diff) | |
download | c++-1fbcb4dd4e52daeb53becba33827f8e48c5606b2.tar.gz c++-1fbcb4dd4e52daeb53becba33827f8e48c5606b2.tar.bz2 c++-1fbcb4dd4e52daeb53becba33827f8e48c5606b2.zip |
fixed major mistake in process, also got n-component version fully working
Diffstat (limited to 'lib/wolff.h')
-rw-r--r-- | lib/wolff.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/wolff.h b/lib/wolff.h index ce7040a..29286ba 100644 --- a/lib/wolff.h +++ b/lib/wolff.h @@ -20,6 +20,8 @@ #include "graph.h" #include "tree.h" #include "measurement.h" +#include "orthogonal.h" +#include "dihedral.h" typedef struct { graph_t *g; @@ -29,12 +31,27 @@ typedef struct { double *H; double *J_probs; double *H_probs; + dihedral_t *R; double E; v_t *M; q_t q; } ising_state_t; +typedef struct { + graph_t *g; + double *spins; + double T; + double (*J)(double); + double (*H)(double *); + double *R; + double E; + double *M; + q_t n; +} vector_state_t; + v_t flip_cluster(ising_state_t *s, v_t v0, q_t s1, gsl_rng *r); +v_t flip_cluster_vector(vector_state_t *s, v_t v0, double *rot, gsl_rng *r); + graph_t *graph_add_ext(const graph_t *g); |