Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

random numbers aren't sampled at onset #1174

Closed
yaxu opened this issue Feb 22, 2025 · 0 comments · Fixed by #1176
Closed

random numbers aren't sampled at onset #1174

yaxu opened this issue Feb 22, 2025 · 0 comments · Fixed by #1176

Comments

@yaxu
Copy link
Member

yaxu commented Feb 22, 2025

PR #1148 hasn't fixed the behaviour of rand:

ghci> queryArc (rand :: Pattern Double) (Arc 0 0)
[~0>0~|0.0]
ghci> queryArc (rand :: Pattern Double) (Arc 0 0.1)
[~0>⅒~|0.9219377599656582]
ghci> queryArc (rand :: Pattern Double) (Arc 0 0.3)
[~0>3/10~|5.677513778209686e-2]

Also note that the first value is 0. When random numbers are sampled at onset, this will cause problems for weighted functions, ref tidalcycles/strudel#1293

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant