Homework 5 - Efficiency Structures


I chose a uniform grid because I felt that it would fit better for this particular problem. I've had nice hours implementing it and realizing that grids suck. The implementation is not optimal at all and still has a strange bug.

Here are the results (for a 200 Mhz SGI R4400 w/ 128M, and nx*ny*nz ~ 3*n):

No. of spheres Preprocess time Trace time
1 ~0 s 8.89 s
10 ~0 s 9.51 s
100 ~0 s 11.13 s
1000 ~0 s 14.67 s
10000 0.08 s 23.37 s
100000 0.95 s 41.11 s
1000000 11.58 s 87.51 s

I think the thing to notice here is that as the number of spheres is increased by a factor of 10, the trace time approximately doubles.


ikits@cs.utah.edu