Advertisement
rfmonk

test2.py

Mar 25th, 2014
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.38 KB | None | 0 0
  1. #!/usr/bin/env python
  2.  
  3.  
  4. from random import uniform
  5. from particle import *
  6.  
  7.  
  8. def benchmark():
  9.     particles = [Particle(uniform(-1.0, 1.0),
  10.                           uniform(-1.0, 1.0),
  11.                           uniform(-1.0, 1.0))
  12.                  for i in range(1000)]
  13.  
  14.     simulator = ParticleSimulator(particles)
  15.     simulator.evolve(0.1)
  16.  
  17.  
  18. if __name__ == '__main__':
  19.     benchmark()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement