Skip to content
rdococ edited this page Sep 14, 2019 · 5 revisions

HyperRogue currently supports four primary geometries, with many tilings and several quotient spaces, in two or three dimensions.

Euclidean geometry

Euclidean geometry is the geometry that we are used to. In Euclidean geometry, given a line and a point, there is one parallel line that crosses the point.

Some interesting aspects of Euclidean geometry are:

  • The angles on the inside of any polygon add up to (n - 2) ⋅ 180°, where n is the number of sides. For triangles, this number is 180°.
  • As a circle grows, its circumference grows linearly, while its area grows quadratically.
  • The limit as a circle grows to infinity is a line.

Hyperbolic geometry

Hyperbolic geometry is the default geometry that HyperRogue starts with, its namesake, and the geometry that inspired the game.

Hyperbolic geometry differs from Euclidean geometry in one key aspect: given a line and a point, there are infinitely many lines that cross the point while not touching the line.

As a result of this, lines that don't intersect in hyperbolic geometry have a point where they are closest, and then diverge from each other in both directions. It's important to note that the lines are still straight - it's the nature of the geometry that makes them diverge, and not the lines themselves curving.

Alternatively, you could have lines that meet up at an infinitely far away point, on the horizon, but the distance between these lines approaches zero, which is less than the width of one tile, so it's not very suitable for HyperRogue. They still diverge in the other direction, however.

The Crossroads and the Great Walls show us that straight lines in hyperbolic geometry can fit together quite tightly, while never running into each other. The Great Walls don't curve in any way, but the geometry makes them diverge from each other nonetheless.

The Land of Eternal Motion shows us that if you're running in a straight line and someone wants to run parallel to you like the Running Dogs do, they will have to run in a curve that constantly curves towards your line, because if they tried to run in a parallel line, their line would diverge from yours. The dogs run at the same speed as you, but their path is longer.

R'Lyeh and the Temple of Cthulhu show us that there are infinitely large circular shapes which curve in just the right amount to close up at the horizon. These are called horocycles. If they were any less curved, they would be hypercycles - curved lines like the ones that Running Dogs have to run to chase you, but if they were any more curved, they would simply be huge circles.

Camelot and the Round Table shows us that even finite circles with small radii can have huge areas. The starting radius of a Round Table is 28, and yet the area that the table covers is so huge that without a special tactic, you have no chance of finding the Holy Grail in the center. To be mathematically precise, as a circle's radius grows, its circumference and area both grow exponentially. There are a ton of knights around that table!

The exponential growth in the circumference of a circle, and in the surface area of a sphere means that as things move away from you, the speed at which they appear to shrink doesn't slow down like it does in Euclidean or spherical geometry. It also means that it's very easy to get completely lost if you walk too far from a given point, and you can't see it anymore - there's just so much extra space that it's hard to find your way back.

Because of the diverging nature of lines in hyperbolic geometry, the angles in polygons add up to less than they should. In fact, they add up to what the angles would add up to in a Euclidean polygon with the same number of sides, minus a value proportional to the area of the polygon. You could use the angle sum of a polygon to measure the area of that polygon.

In addition, because parallel lines diverge, your eyes won't be able to see anything if they try to look in parallel, and they have to converge in order to focus on anything. It will look like you're inside a sphere a few meters wide, with far away things appearing small, but not that far away.

Spherical geometry

Spherical geometry is the geometry found on the surface of a sphere. However, being in spherical geometry is not the same as being on the surface of a sphere. Only 2D beings that are embedded within the surface of the sphere, and know nothing about the space outside the sphere, are living in spherical geometry.

In spherical geometry, given a line and a point, there are no lines that cross the point while not touching the line. You can think of this on the surface of an actual sphere, where two great circles will always intersect at one or more points.

The angles of a polygon add up to the angle that they would add up to in Euclidean geometry, plus a value proportional to the area of the polygon instead of minus, and instead of circles becoming hypercycles when they get infinitely big, they become straight lines in spherical geometry at a finite size.

Because lines always intersect in spherical geometry, something that gets further away from you will begin to get larger and larger, until they seem to cover the entire world. This is because you are getting closer to the point where the light rays from the object converge from all directions.

This applies to your head, too, which means that if you found yourself inside spherical geometry, an inverted version of your head would cover the world at all times.

Product geometries

You can stack 2D non-euclidean geometries on top of each other in a Euclidean way, and what you get is a product geometry.

In H2xE, a geometry where hyperbolic planes are stacked in such a way, things going into the distance appear to squish horizontally more than they do vertically. This is because the light rays from those things diverge more horizontally than they do vertically, because the geometry is hyperbolic horizontally, but Euclidean vertically.

In S2xE, a geometry where spherical planes are stacked, the opposite is true - things going into the distance appear to squish horizontally at first, before slowing down and then expanding until they appear as a ring surrounding you. This is because the geometry is spherical horizontally, but Euclidean vertically.

Solv

Solv geometry, also known as Sol geometry, is an unusual type of geometry. Unlike the previous three, it is not described by the modification of the rule applying to parallel lines (Euclid's parallel postulate in Euclidean geometry), but by a rule that applies to lines parallel to the Z axis.

As you move in the Z direction in Solv, the X direction scales up while the Y direction scales down. If they both scaled up, what you would get is a model of standard hyperbolic space, where the great walls would be concentric horospheres instead of the hyperbolic planes they are in standard 3D mode.

However, because the dimensions scale in opposite ways, the great walls can't decide if you're inside or outside them. Great walls appear to curve towards you in one dimension, and away in the other, and which one curves which way swaps if you go through the great wall.

The great walls behave like horospheres in other ways, too. The geometry on the surface of a Solv great wall is Euclidean, and if you move diagonally, you may eventually end up facing directly towards or away from a great wall.

This is similar to how if you move in any direction other than straight towards a horosphere's center in standard hyperbolic space, you miss the center and eventually end up facing almost directly away from it.

Solv geometry has many, much stranger characteristics, but this is a good starting point for learning about it.

Clone this wiki locally