def fast_random_series (   self,
  count 
)

Reimplemented in r250_521.

Definition at line 131 of file r250.py.

00131                                        :
00132         "return a series of 31-bit ints much more quickly than individual calls to next()."
00133         results=Numeric.zeros(count, numeric_int32)
00134         first=min(count, self.p-self.counter) #how many are already in the buffer that we want?
00135         results[:first]=self.ranbuf[self.counter:self.counter+first]
00136         #print self.ranbuf[self.counter], results.tolist()
00137         count-=first
00138         self.counter+=first
00139         if self.counter==self.p: #used up all in buffer, start generating more
00140             self.regenerate()
00141             for i in range(count//self.p):
00142                 results[first:first+self.p]=self.ranbuf
00143                 first+=self.p
00144                 count-=self.p
00145                 self.regenerate()
00146             if count:
00147                 results[first:]=self.ranbuf[:count]
00148                 self.counter=count
00149         return results
00150 
    def single_float_random_series(self, count):


Generated on Wed Nov 21 10:18:33 2007 for analysis by  doxygen 1.5.4