Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/lamont/test/implicit-surface/gl_version/unit-circle.diderot
ViewVC logotype

Diff of /branches/lamont/test/implicit-surface/gl_version/unit-circle.diderot

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3281, Tue Oct 13 17:05:21 2015 UTC revision 3282, Tue Oct 13 19:46:34 2015 UTC
# Line 45  Line 45 
45      vec2 force = [0,0];   // or can test convergence based on sum of |force|      vec2 force = [0,0];   // or can test convergence based on sum of |force|
46      update {      update {
47                  hasNeighbors = false;                  hasNeighbors = false;
48          if(stdev <= threshold && !newNeigbor)  {          if(!newNeigbor)  {
49              stabilize;              stabilize;
50          }          }
51    
# Line 108  Line 108 
108  // can add statements in here to do some global computation  // can add statements in here to do some global computation
109  global{  global{
110    iter+=1;    iter+=1;
111    real var = variance{P.energy | P in Particle.all};  //  real var = variance{P.energy | P in Particle.all};
112    newNeigbor = exists{P.hasNeighbors | P in Particle.all};    newNeigbor = exists{P.hasNeighbors | P in Particle.all};
113    oldStdev = stdev;   // oldStdev = stdev;
114    stdev = sqrt(var);   // stdev = sqrt(var);
115    //print("stdev = ", stdev, "\n");    //print("stdev = ", stdev, "\n");
116  }  }
117    

Legend:
Removed from v.3281  
changed lines
  Added in v.3282

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0