1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
| #include<stdio.h>
| #include<math.h>
| #include "general.h"
| #include "vertex.h"
| #include "bond.h"
| #include "triangle.h"
| #include "cell.h"
| #include "vesicle.h"
| #include "io.h"
| #include "initial_distribution.h"
| #include "frame.h"
| #include "timestep.h"
|
|
| int main(int argv, char *argc[]){
| ts_vesicle *vesicle;
| ts_uint inititer,mcsweeps, iterations;
| vesicle=parsetape(&mcsweeps, &inititer, &iterations);
|
| int i,j,k;
| /* TAINTING TEST */
| for(k=0;k<2;k++){
|
| printf("*** Starting test No. %d\n",k+1);
| for(i=0;i<vesicle->vlist->n;i++){
| vertex_taint(vesicle->vlist->vtx[i],1);
| vertex_untaint(vesicle->vlist->vtx[i],1);
| printf("%d taint amount %u\n",i,*(vesicle->vlist->vtx[i]->locked));
| if(vertex_tainted(vesicle->vlist->vtx[i], 0, 1)) printf("Ooops, Main %d is tainted!\n",i);
| for(j=0;j<vesicle->vlist->vtx[i]->neigh_no;j++){
| if(vertex_tainted(vesicle->vlist->vtx[i]->neigh[j], 0, 1)){
| printf("Ooops, The neighbour %d of %d is tainted!\n", j, i);
| }
| }
|
| }
| }
|
|
| printf("At the end you should see no Ooopses and all taint amounts should be 0!\n");
| vesicle_free(vesicle);
| return 0;
| }
|
|