Commit eee750a7 authored by Cassio Kirch's avatar Cassio Kirch

STEPS + 1 steps.

parent 0547ec33
......@@ -27,8 +27,9 @@ getAverageNeighborsNo(const struct Boid* const boid)
unsigned int boidCount;
double averageNeighborsNo = 0.0;
for (boidCount = 0; boidCount < N; ++boidCount)
averageNeighborsNo += (double)(boid[boidCount].endoNeighbors + \
boid[boidCount].ectoNeighbors) / N;
averageNeighborsNo += ((double)boid[boidCount].endoNeighbors + \
(double)boid[boidCount].ectoNeighbors);
averageNeighborsNo /= N;
return averageNeighborsNo;
}
#endif
......@@ -139,7 +140,7 @@ one_system ()
for (boidCount=0; boidCount<N; boidCount++)
appendBoid(&(boid[boidCount]), box);
for (step=0; step<STEPS; ++step)
for (step=0; step <= STEPS; ++step)
{
nextStep(parameters);
for (boidCount=0; boidCount<N; boidCount++)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment