Math Related Things

less than 1 minute read

Relation between Density and Histrogram funcion

Given , where is the density function of , and the width of each bin , we can produce histrogram function , by sampling variable times, resulting in .
Then, there’s a conclusion: .

How to generate a random direction?

When doing academic research, I need to generate a random direction, i.e. it points to any direciton in an equalled probability. At first, I thought, assign each dimension a random value(Uniform Distribution) is sufficient. After second thought, I find out it’s not correct.
Let’s say, a N-dimension direction is defined by .

  • If we just let be a random variable, i.e. , is NOT a random direction.

  • To generate a truly random direction, we can let , where N(0,1) is a Normal Distribution with , , at this time, points to every direction in the same probability. And length of ,

Updated:

Comments

Very nice post. I just stumbled upon your weblog and wished to say that I have really enjoyed browsing your blog posts. After all I’ll be subscribing to your feed and I hope you write again soon!

Leave a Comment

Your email address will not be published. Required fields are marked *

Loading...