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

SCM Repository

[diderot] Diff of /branches/lamont/test/reduction/reduction-test.diderot
ViewVC logotype

Diff of /branches/lamont/test/reduction/reduction-test.diderot

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

revision 2098, Mon Nov 26 17:14:36 2012 UTC revision 2101, Thu Dec 6 06:37:07 2012 UTC
# Line 10  Line 10 
10   * All rights reserved.   * All rights reserved.
11   */   */
12    
13  int{} args = load("energies.nrrd");  real{} energies = load("energies.nrrd");
14  int nArgs = length(args);  int nEnergies = length(energies);
 int worldHeight = 234;  
15  strand Particle (real initEnergy) {  strand Particle (real initEnergy) {
16      real energy = initEnergy;      real energy = initEnergy;
17      output real maxEnergy = 0.0;      output real maxEnergy = 0.0;
 // && Particle.stable  
18    
19      update {      update {
20             int count = 45;
21           maxEnergy = max{P.energy | P in {Particle.active && Particle.stable}};           maxEnergy = max{P.energy | P in {Particle.active && Particle.stable}};
22             real minEnergy = min{P.energy | P in {Particle.active && Particle.stable}};
23             bool yes = xor{S.energy < 45 | S in {Particle.active}};
24             print("****", "\n", maxEnergy, "\n", minEnergy, "\n", yes, "\n", "*****", "\n", "\n");
25           stabilize;           stabilize;
26      }      }
27  }  }
28    
29  initially [ Particle(vi) | vi in 0..(nArgs-1)];  initially [ Particle(energies{vi}) | vi in 0..(nEnergies-1)];

Legend:
Removed from v.2098  
changed lines
  Added in v.2101

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