1

Is it possible to use the H3 grid system for celestial tilling? I want to use the (alpha, delta)=(right ascension, declinaison) coordinate system (equatorial coordinate system) to assign a point/galaxy to a tile and then collect all the points (galaxies) of a particular tile, find the neighboring tiles, and get an unique indexing of the tiles.

nrabinowitz
  • 55,314
  • 10
  • 149
  • 165
Jean-Eric
  • 372
  • 2
  • 14

1 Answers1

0

This should be fine, as long as you have function to transform equatorial coordinates into lat/long coordinates. The inputs for H3 are expected to be lat/long points, specified as either degrees (for most of the bindings, e.g. h3-js and h3-py), or radians (for the core C library). Assuming you have a function to translate the (ascension, declination) tuple to a (lat, long) tuple, then H3 should be entirely adequate as a grid system for any spherical coordinates.

The only Earth-centric aspects of H3 are:

  • The initial orientation of the icosahedron the grid is based on, which is optimized to place the vertices in Earth's oceans

  • Any functions like hexArea or edgeLength which output units of kilometers or meters based on the Earth's radius.

Other than these, the grid system should work for any spherical context.

nrabinowitz
  • 55,314
  • 10
  • 149
  • 165
  • Great! So I will try. Is there a skeleton to get some visualisaton of the whole sphere and zoom on my (lat, long) points? Concerning `hexArea` and `edgeLength` I guess so I can rescale by 1/R^2 or 1/R with R=6000km or so (if yes, what is the exact value used in H3?) Concerning the global orientation, does the Noth/South pole are filed with a pentagon? – Jean-Eric Jul 02 '20 at 07:09
  • I forgot to ask: is there by chance a Scala interface? – Jean-Eric Jul 02 '20 at 07:28
  • The exact radius used by H3 is here: https://github.com/uber/h3/blob/master/src/h3lib/include/constants.h#L59 – nrabinowitz Jul 03 '20 at 14:30
  • The icosahedron uses a version of the Dymaxion layout, which is not oriented based on the poles, but instead focused on putting vertices in oceans. I don’t think either pole is covered by a pentagon at the coarsest resolution (I’d need to double check, but if they were it would be incidental, as the vertices are not aligned with poles) – nrabinowitz Jul 03 '20 at 14:34
  • Known bindings are listed here: https://h3geo.org/docs/community/bindings - there isn’t a Scala binding, but I think Scala can use the Java bindings? – nrabinowitz Jul 03 '20 at 14:38
  • Ok Thanks a lot. concerning the Dymaxion layout I was wandering if there is a (lat,long) transformation one can used from H3 to be in a system with pentagons at poles (N & S) and a petagon located near equator at long=0 ? – Jean-Eric Jul 04 '20 at 12:23
  • No, that’s not possible, due to the shape of the icosahedron. See illustrations in http://webpages.sou.edu/~sahrk/sqspc/pubs/gdggs03.pdf - you have to choose pentagons at poles or at the equator, you can’t have both – nrabinowitz Jul 04 '20 at 16:16
  • To find a translation, simply find one of the res 0 pentagons using getPentagonIndexes and get the translation from its center to a pole of your choice – nrabinowitz Jul 04 '20 at 16:19
  • Thanks. I guess it is not just a translation but rotations,, no? – Jean-Eric Jul 06 '20 at 08:49
  • Yes, I meant a rotational translation, which maybe is misusing the term `translation`. – nrabinowitz Jul 06 '20 at 16:47