-
-
Notifications
You must be signed in to change notification settings - Fork 930
Add Gauss random function #2931
Copy link
Copy link
Open
Labels
status:pendingPending acceptance or closure.Pending acceptance or closure.type:feature-requestRequest for something newRequest for something new
Description
The Problem
Currently it is not simple to create using a gauss/normal distribution. It is one of the most commonly found naturally occurring distributions.
A Solution
create a gauss() function. It should take mean and standard deviation parameters.
Alternatives
It is possible to manually implement the distribution into an expression. If you add 12 random() outputs together and then subtract that from 6, the result will be a close approximation to a gauss distribution.
For example, generating a patch of path blocks that decay radially using this implementation:
//g dirt_path a=0; for(b=0;b<12;b++){a+=random();} (6-a)^2>(x*2)^2+(z*2)^2
But it would be much simpler and faster to be able to write //g dirt_path gauss(0,1)>(x*2)^2+(z*2)^2
Anything Else?
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
status:pendingPending acceptance or closure.Pending acceptance or closure.type:feature-requestRequest for something newRequest for something new