csound-expression-0.0: src/CsoundExpr/Opcodes/Math/Rndfunc.hs
-- | Random Functions
module CsoundExpr.Opcodes.Math.Rndfunc
(birnd,
rnd)
where
import CsoundExpr.Base.Types
import CsoundExpr.Base.MultiOut
import CsoundExpr.Base.SideEffect
import CsoundExpr.Base.UserDefined
-- | * opcode : birnd
--
--
-- * syntax :
--
-- > birnd(x) (init- or control-rate only)
--
--
-- * description :
--
-- Returns a random number in a bi-polar range.
--
--
-- * url : <http://www.csounds.com/manual/html/birnd.html>
birnd :: (K k0) => k0 -> k0
birnd k0sig = prefixOperation "birnd" args
where args = [to k0sig]
-- | * opcode : rnd
--
--
-- * syntax :
--
-- > rnd(x) (init- or control-rate only)
--
--
-- * description :
--
-- Returns a random number in a unipolar range at the rate given by
-- the input argument.
--
--
-- * url : <http://www.csounds.com/manual/html/rnd.html>
rnd :: (K k0) => k0 -> k0
rnd k0sig = prefixOperation "rnd" args
where args = [to k0sig]