LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

levy flight implementation in 2D walk

Solved!
Go to solution

Hello,

I am trying to draw the walk of the levy flights in a 2D space to get a similar plot as this.

https://en.wikipedia.org/wiki/L%C3%A9vy_flight

I found that I can use the Gamma inverse function to generate the gamma distribution of the random number that I can multiply to the coordinates (x,y) to get  every new step. First, I would like to double check if this is correct and doable with Labview.

I found in wikipedia this approximation that may be useful.

 

I made a draft of the Vi and I would be very grateful if anyone can help me or post any comment.

Thanks,

Zied

 

0 Kudos
Message 1 of 4
(5,177 Views)

Hi ziedhosni,

 

I would think this is doable in LabVIEW, but I'm a little confused.  Can you clarify what you're hoping to get from posting on the forums? Is your current VI not working? Are you getting any errors?  Forum posts tend to get more responses if they have an explicit question, so let us know!

Ashley G.
Senior Applications Engineer | RF & Wireless Communications
Message 2 of 4
(5,128 Views)

Hi Ashly,

Thanks for your reply.

What I am trying to do is to draw the following plot.

256px-LevyFlight.svg.png

It start by choosing a random coordinates (x,y) for a point in the 2D space and then apply the Levy flight distribution for the random walk(step) to move the point in the space.

According to wikipedia, the levy flight distribution can be approximate by the inverse gamma CDF that is already implemented in Labview.

 

But I am not sure how to use this function in labview and I did not find any example that shows how to use it.

Thanks,

Zied

0 Kudos
Message 3 of 4
(5,098 Views)
Solution
Accepted by topic author ziedhosni

Seemed like something fun to try (one of the few remaining sections in Mandlebrot's book that I have not yet recreated), I use the Inv-Normal Distribution instead of the Inv-Gamma to get the Levy distributed steps.  Choose a random angle between 0 and 2pi along with Levy distributed step length.

 

LevyFlight.png

 

LevyFlightBD.png

 

Message 4 of 4
(5,071 Views)