Advertisement
Zer0Div

Untitled

Oct 3rd, 2019
207
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.29 KB | None | 0 0
  1. def generate_poi(lati, long):
  2.     u = random.uniform(0.1,1.0)
  3.     v = random.uniform(0.1,1.0)
  4.     r = 200/111139
  5.     w = r * math.sqrt(u)
  6.     t = 2 * math.pi * v
  7.     x = w * math.cos(t)
  8.     y = w * math.sin(t)
  9.     gen_lati = lati+x
  10.     gen_long = long+y
  11.     return gen_lati, gen_long
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement