generate random numbers subject to

1 次查看(过去 30 天)
Hi, I am trying to generate a set of random numbers X between 0 and 1 subject that an equation depending on X can be negative. Thanks a lot,

回答(1 个)

Image Analyst
Image Analyst 2016-4-18
You need to do inverse transform sampling. https://en.wikipedia.org/wiki/Inverse_transform_sampling This involves getting the CDF of the equation. I attach a Rayleigh example.

类别

Help CenterFile Exchange 中查找有关 Random Number Generation 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by