Trisurf Monte Carlo simulator
Samo Penic
2018-06-27 6da644f98434d3eac8b4e19981754f6030a315a5
src/vertexmove.c
@@ -165,7 +165,7 @@
   if(vesicle->tape->constvolswitch==2){
      /*check whether the dvol is gt than epsvol */
         //fprintf(stderr,"DVOL=%1.16e\n",dvol);
         //fprintf(stderr,"DVOL=%1.16e, V0=%1.16e, vesicleVolume=%1.16e, |volume+dvol-V0|=%1.16e\n",dvol, V0, vesicle->volume, fabs(vesicle->volume+dvol-V0));
      if(fabs(vesicle->volume+dvol-V0)>epsvol){
         //restore old state.
          vtx=memcpy((void *)vtx,(void *)&backupvtx[0],sizeof(ts_vertex));
@@ -173,11 +173,12 @@
                 vtx->neigh[i]=memcpy((void *)vtx->neigh[i],(void *)&backupvtx[i+1],sizeof(ts_vertex));
              }
                  for(i=0;i<vtx->tristar_no;i++) triangle_normal_vector(vtx->tristar[i]); 
                  //fprintf(stderr,"fajlam!\n");
               //   fprintf(stderr,"fajlam!\n");
                  return TS_FAIL;
      }
   } else
      //fprintf(stderr, "success\n");
//    vesicle_volume(vesicle);
//    fprintf(stderr,"Volume before=%1.16e\n", vesicle->volume);
   if(vesicle->tape->constvolswitch == 1){