# Plot Fibonacci lattice
plot(sph_to_hammer(fib_latt(n = 1000)))
points(sph_to_hammer(rbind(c(0, 0, 1), c(0, 0, -1))), col = 2, pch = 19)
points(sph_to_hammer(rbind(c(1, 0, 0), c(-1, 0, 0))), col = 3, pch = 19)
points(sph_to_hammer(rbind(c(0, 1, 0), c(0, -1, 0))), col = 4, pch = 19)
# Check changes of coordinates
hammer_to_sph(sph_to_hammer(rbind(c(1, 0, 0), c(0, 1, 0))))
sph_to_hammer(hammer_to_sph(rbind(c(0, 0), c(0.5, 0.5))))
Run the code above in your browser using DataLab