From: hackbard Date: Fri, 9 May 2003 15:15:15 +0000 (+0000) Subject: fixed delta e bug X-Git-Url: https://hackdaworld.org/gitweb/?a=commitdiff_plain;h=78fcc4451906fd4fbc2830fc72fd511563d9bf98;p=physik%2Fising.git fixed delta e bug --- diff --git a/Makefile b/Makefile index 5419453..95124d1 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # ising Makefile -INCLUDEDIR = /usr/include -CFLAGS = -DDEBUG -DUSE_DFB_API -DFONT=\"./decker.ttf\" -O3 -Wall -I/usr/include/directfb +INCLUDEDIR = /usr/local/include +CFLAGS = -DDEBUG -DUSE_DFB_API -DFONT=\"./decker.ttf\" -O3 -Wall -I/usr/local/include/directfb LIBS = -L/usr/lib -ldirectfb OBJS = dfbapi.o diff --git a/ising.c b/ising.c index dd538b3..e43b4be 100644 --- a/ising.c +++ b/ising.c @@ -11,11 +11,12 @@ #include #include #include +#include #include "dfbapi.h" -#define X 100 -#define Y 100 -#define MAX_T 200 +#define X 200 +#define Y 200 +#define MAX_T 100 int main(int argc, char **argv) { @@ -33,6 +34,9 @@ int main(int argc, char **argv) double beta; double delta_e; + /* random stuff*/ + srand(time(0)); + /* display stuff */ d2_lattice d2_l; @@ -53,9 +57,9 @@ int main(int argc, char **argv) for(T=1;T