From dcf17d56fd0a7c361e5076c3023e628effb7fa5f Mon Sep 17 00:00:00 2001
From: Samo Penic <samo.penic@gmail.com>
Date: Wed, 27 Nov 2013 19:10:16 +0000
Subject: [PATCH] Returning back to 142a67fe82b830e5c7816914afa62445959c87ca

---
 src/timestep.c |   18 ++++++------------
 src/vertex.c   |   33 ---------------------------------
 src/tape       |    4 ++--
 src/general.h  |    1 -
 src/vertex.h   |    4 +---
 5 files changed, 9 insertions(+), 51 deletions(-)

diff --git a/src/general.h b/src/general.h
index 1dfb3a7..f3328f6 100644
--- a/src/general.h
+++ b/src/general.h
@@ -154,7 +154,6 @@
         ts_double projArea;
         ts_double relR;
         ts_double solAngle;
-	ts_int locked;
 };
 typedef struct ts_vertex ts_vertex;
 
diff --git a/src/tape b/src/tape
index d6e814d..0351c83 100644
--- a/src/tape
+++ b/src/tape
@@ -19,9 +19,9 @@
 #how many MC sweeps between subsequent records of states to disk
 mcsweeps=100
 #how many initial mcsweeps*inititer MC sweeps before recording to disk?
-inititer=10
+inititer=100
 #how many records do you want on the disk iteration are there in a run?
-iterations=100
+iterations=1000
 
 
 #shut up if we are using cluster!!!
diff --git a/src/timestep.c b/src/timestep.c
index c25c1fb..9e5e61c 100644
--- a/src/timestep.c
+++ b/src/timestep.c
@@ -7,7 +7,6 @@
 #include "vertexmove.h"
 #include "bondflip.h"
 #include "frame.h"
-#include "vertex.h"
 #include "io.h"
 ts_bool run_simulation(ts_vesicle *vesicle, ts_uint mcsweeps, ts_uint inititer, ts_uint iterations){
 	ts_uint i, j;
@@ -31,25 +30,21 @@
 ts_bool single_timestep(ts_vesicle *vesicle){
     ts_bool retval;
     ts_double rnvec[3];
-    ts_uint i;// b;
+    ts_uint i, b;
     for(i=0;i<vesicle->vlist->n;i++){
         rnvec[0]=drand48();
         rnvec[1]=drand48();
         rnvec[2]=drand48();
-	vertex_taint(vesicle->vlist->vtx[i],1);
-//		ts_fprintf(stdout, "Vertex %d should be tainted, level=%d.\n", i, vesicle->vlist->vtx[i]->locked);
-	if(vertex_tainted(vesicle->vlist->vtx[i],1,1)){
-		ts_fprintf(stdout, "Vertex %d tainted, level=%d. Waiting....\n", i, vesicle->vlist->vtx[i]->locked);
-		while(vertex_tainted(vesicle->vlist->vtx[i],1,1));
-	}
         retval=single_verticle_timestep(vesicle,vesicle->vlist->vtx[i],rnvec);
-	vertex_untaint(vesicle->vlist->vtx[i],1);
-//		ts_fprintf(stdout, "Vertex %d should be untainted, level=%d.\n", i, vesicle->vlist->vtx[i]->locked);
     }
 
 //	ts_int cnt=0;
-/*
     for(i=0;i<vesicle->vlist->n;i++){
+//why is rnvec needed in bondflip?
+/*        rnvec[0]=drand48();
+        rnvec[1]=drand48();
+        rnvec[2]=drand48();
+*/ 
 	b=rand() % vesicle->blist->n;
         //find a bond and return a pointer to a bond...
         //call single_bondflip_timestep...
@@ -57,7 +52,6 @@
 //	if(retval==TS_SUCCESS) cnt++;        
     } 
 //	printf("Bondflip success rate in one sweep: %d/%d=%e\n", cnt,vesicle->blist->n,(double)cnt/(double)vesicle->blist->n);
-*/
 	if(retval);
     return TS_SUCCESS;
 }
diff --git a/src/vertex.c b/src/vertex.c
index 1993856..38647aa 100644
--- a/src/vertex.c
+++ b/src/vertex.c
@@ -311,36 +311,3 @@
 
     return vlist;
 }
-
-
-
-ts_bool vertex_taint(ts_vertex *vtx, ts_uint level){
-	if(level==0){
-		vtx->locked++;
-		return TS_SUCCESS;	
-	}	
-	ts_uint i;
-	for(i=0; i<vtx->neigh_no; i++){
-		vertex_taint(vtx->neigh[i], level-1);
-	}
-		vtx->locked++;
-	return TS_SUCCESS;
-}
-
-ts_bool vertex_untaint(ts_vertex *vtx, ts_uint level){
-	if(level==0){
-		vtx->locked--;
-		return TS_SUCCESS;	
-	}	
-	ts_uint i;
-	for(i=0; i<vtx->neigh_no; i++){
-		vertex_untaint(vtx->neigh[i], level-1);
-	}
-		vtx->locked--;
-	return TS_SUCCESS;
-}
-
-inline ts_bool vertex_tainted(ts_vertex *vtx, ts_uint level, ts_uint amount){
-	if(vtx->locked>amount) return 1;
-	else return 0;
-}
diff --git a/src/vertex.h b/src/vertex.h
index 7f494c6..97775d2 100644
--- a/src/vertex.h
+++ b/src/vertex.h
@@ -30,7 +30,5 @@
 ts_bool vtx_duplicate(ts_vertex *cvtx, ts_vertex *ovtx);
 ts_vertex **vtx_neigh_copy(ts_vertex_list *vlist,ts_vertex *ovtx);
 ts_vertex_list *vertex_list_copy(ts_vertex_list *ovlist);
-ts_bool vertex_taint(ts_vertex *vtx, ts_uint level);
-ts_bool vertex_untaint(ts_vertex *vtx, ts_uint level);
-inline ts_bool vertex_tainted(ts_vertex *vtx, ts_uint level, ts_uint amount);
+
 #endif

--
Gitblit v1.9.3