====== Tesseract ====== A Tesseract is a four dimensional hypercube. While a square goes one unit in all four quadrants of a 2D graph, a cube goes one unit in all 8 octants on a 3D graph (the 3rd direction going off at a 45 degree axis), the tesseract goes one unit in all 16-hyperoctants of a a 4D graph (the 4th dimension going off at a 135 degree axis). This example is for use with Red-Cyan 3D (Anaglyph) glasses. The rotation formulas are from Volume 1, Chapter 7, page 149 of A.R. Forsyth's **Geometry of Four Dimensions** Cambridge University Press, 1930 [[https://archive.org/details/geometryoffourdi032760mbp/]]. {{point.java|Point.java}} {{edge.java|Edge.java}} {{tesseract.java|Tessaract.java}} {{orthograph.java|OrthoGraph.java}} The 3D effect works well when it is animated, but here are some screen-shots: {{:tesseract1.png?400|}} {{::tesseract2.png?400|}} Things to Try: - Make a single black lined Tesseract - Make a [[https://mathorama.com/apcs/pmwiki.php?n=Main.ButtonApplication|button]] or hot spot to switch between the Black and the Red-Cyan view - Rather than a timer, make the rotation from MouseMovements (Look [[https://mathorama.com/apcs/pmwiki.php?n=Main.MouseMotionListenerApplication|here]] for how to get info from a MouseMotionListener - Draw one of the squares in a different color so you can easily follow it around Other Links - [[https://mathorama.com/wiki/doku.php?id=hunt_the_wumpus|Hunt The Wumpus]] - [[https://mathorama.com/apcs/pmwiki.php?n=Main.Applications|Starter Code for your Own Applications]] - [[https://mathorama.com/apcs/pmwiki.php?n=Main.MouseListenerApplication|Mouse Listener Application]] - [[https://mathorama.com/apcs/pmwiki.php?n=Main.MouseMotionListenerApplication|Mouse Motion Listener Application]] - [[https://mathorama.com/apcs/pmwiki.php?n=Main.ButtonApplication|Button Application]]