From c60a49ec71004bad2af9ca8b3240c035a7ab8d2a Mon Sep 17 00:00:00 2001
From: mihaf <miha.fosnaric@gmail.com>
Date: Tue, 03 Jun 2014 10:04:57 +0000
Subject: [PATCH] Added random seed.

---
 src/io.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/src/io.c b/src/io.c
index d001b7e..3fecef5 100644
--- a/src/io.c
+++ b/src/io.c
@@ -170,7 +170,8 @@
 */
 
 	fwrite(vesicle->clist, sizeof(ts_cell_list),1,  fh);
-	
+/* write tape information on vesicle */
+    fwrite(vesicle->tape,sizeof(ts_tape),1,fh);
 	fwrite(&iteration, sizeof(ts_uint),1,fh);
     fclose(fh);
     return TS_SUCCESS;
@@ -428,6 +429,9 @@
         	vesicle->clist->cell[i]->idx=i+1; // We enumerate cells! Probably never required!
     	}
 
+//recreating stored tape information//
+    vesicle->tape=(ts_tape *)malloc(sizeof(ts_tape));
+    retval=fread(vesicle->tape, sizeof(ts_tape),1,fh);
 	retval=fread(iteration,sizeof(ts_uint),1,fh);
     if(retval); 
     fclose(fh);
@@ -973,6 +977,8 @@
 	CFG_SIMPLE_FLOAT("dmin_interspecies", &tape->dmin_interspecies),
         CFG_SIMPLE_FLOAT("xk0",&tape->xk0),
 	CFG_SIMPLE_INT("pswitch",&tape->pswitch),
+	CFG_SIMPLE_INT("constvolswitch",&tape->constvolswitch),
+	CFG_SIMPLE_FLOAT("constvolprecision",&tape->constvolprecision),
 	CFG_SIMPLE_FLOAT("pressure",&tape->pressure),
 	CFG_SIMPLE_FLOAT("k_spring",&tape->kspring),
 	CFG_SIMPLE_FLOAT("xi",&tape->xi),

--
Gitblit v1.9.3