Download Maple T.A. User Guide
Transcript
271 • Authoring Mathematical Questions Random Integer Generation range(n), range(m, n), range(m, n, k) The range function returns random integers from a range defined with a step size. range(n) The range(n) function, where n>=1, generates a random integer in the range 1, ..., floor(n) (inclusive). There are floor(n) numbers in that range. Hence, it is a selection of one number from a choice of floor(n). range(m,n) The range(m,n) function, where n-m>=0, generates a random integer in the range m, m+1,..., m+q (inclusive) where q is the floor of n-m range(m,n,k) The range(m,n,k) function, where (n-m)/k=0 generates a random integer in the range m, m+k, ..., m+q*k (inclusive) where q is the floor of (n-m)/k. That is, range(n) = range(1,n) = range(1,n,1) Examples range(3) returns 1, 2, or 3. range(2,3) returns 2 or 3. range(0,7,3) returns 0, 3, or 6. range(0,8,3) returns 0, 3, or 6. range(0,9,3) returns 0, 3, 6, or 9. Note: The rint function returns random numbers in the range 0, ..., n-1 (inclusive). See Also: rand(m, n), rand(m, n, k) (page 270) Random Integer Generation rint(n), rint(m, n), rint(m, n, k) (page 272) Generating Random Numbers in Questions (page 262) rank(n, a, b, c, d, ...) Returns the nth largest element item from a list. (Numbering starts at 1) For example, rank(3, 2, 4, 6, 5, 7) returns 5
Related documents
Maple T.A. User Guide
User Guide - Maplesoft
ION Script User's Guide
Enercon Plus Jr - Alex
Patterning Key - user manual
Manual "Rotas Archive Evaluation"
Maple Programming Guide
Maple User Manual
Maple User Manual - University Information & Technology Services
Maple User Manual
Yard-Man 122118R Specifications
Mathomatic User Guide