Changeset 8435 in project
 Timestamp:
 02/13/08 07:40:01 (12 years ago)
 Location:
 release/3/srfi27/trunk
 Files:

 3 edited
Legend:
 Unmodified
 Added
 Removed

release/3/srfi27/trunk/mrg32k3aprimitives.scm
r8432 r8435 171 171 ; 0 3 6 9 12 15 of A^16, see below 172 172 (f64vector 173 1 250826159174 3004357423175 431373563176 3322526864177 623307378178 2983662421) )173 1062452522 174 2961816100 175 342112271 176 2854655037 177 3321940838 178 3542344109) ) 179 179 180 180 (define (mrg32k3aunpackstate packedstate) 
release/3/srfi27/trunk/srfi27.setup
r8432 r8435 10 10 'numbers "1.8") 11 11 12 #13 12 (installdynld entropystructures *version*) 14 13 … … 30 29 31 30 (installdynld srfi27largenumbers *version* O3 d0) 32 #33 31 34 32 (installdynld mrg32k3aprimitives *version* O3 d0 +easyffi +dollar) … … 41 39 (installdynld moa *version*) 42 40 43 #44 41 (installdynld srfi27parameters *version*) 45 42 … … 47 44 48 45 (installdynld+docu srfi27 *version*) 49 # 
release/3/srfi27/trunk/tests/conftest.scm
r8432 r8435 197 197 (display "check A^16 * (1 0 0 1 0 0): ") (flushoutput) 198 198 (let* ((s (makerandomsource)) 199 ( state1(randomsourcestateref s))199 (initialstate (randomsourcestateref s)) 200 200 (rand (randomsourcemakereals s))) 201 201 (randomsourcestateset! s '(lecuyermrg32k3a 1 0 0 1 0 0)) 202 202 (do ((k 0 (fx+ k 1))) 203 203 ((fx= k 16) 204 (let ((state2 (randomsourcestateref s))) 205 (unless (equal? state1 state2) 206 (error 'checkmrg32k3a "16th state after (1 0 0 1 0 0) is wrong" state1 state2)))) 207 (print "State " k ": " (randomsourcestateref s)) 204 (let ((state (randomsourcestateref s))) 205 (unless (equal? initialstate state) 206 (error 'checkmrg32k3a "16th state after (1 0 0 1 0 0) is wrong" initialstate state)))) 208 207 (rand) ) ) 209 208 (print "ok") … … 211 210 ; check if pseudorandomize! advances properly 212 211 (display "checking randomsourcepseudorandomize! in [1 2] advance: ") (flushoutput) 213 (let ((s (makerandomsource)) 214 (initialstate (randomsourcestateref s))) 215 (randomsourcepseudorandomize! s 1 2) 216 (let ([state (randomsourcestateref s)]) 217 (unless (equal? state initialstate) 218 (error 'checkmrg32k3a "pseudorandomize! gives wrong result" state initialstate)))) 212 (let ((s (makerandomsource))) 213 (randomsourcepseudorandomize! s 1 2) 214 (let ((initialstate (randomsourcestateref s))) 215 (randomsourcepseudorandomize! s 1 2) 216 (let ([state (randomsourcestateref s)]) 217 (unless (equal? state initialstate) 218 (error 'checkmrg32k3a "pseudorandomize! gives wrong result" initialstate state))))) 219 219 (print "ok") 220 220
Note: See TracChangeset
for help on using the changeset viewer.