; The probability that the sum of the squares of k independent random normal deviates is less than x is F(x; k). (define t (let ((sc 10000)) (let ((F ((fileVal "Chi2") 'F))(sg ((fileVal "RND") "murlcrt"))) (lambda (x k) (let ((sv (let w ((n sc) (s 0)) (if (zero? n) s (w (- n 1) (+ s (if (< (let r ((n k)) (if (zero? n) 0 (let ((w (sg))) (+ (* w w) (r (- n 1)))))) x) 1 0))))))) (list sv (* sc (F x k)))))))) (t 2.31 2) => (6777 6849.4246309658665) (t 2.31 5) => (1913 1952.0297107440028) (t 7.4 5) => (8072 8074.495669205999) (t 9.1 4) => (9393 9413.52015669624)