Copyright | (c) Chris Reade 2021 |
---|---|
License | BSD-style |
Maintainer | chrisreade@mac.com |
Stability | experimental |
Safe Haskell | None |
Language | GHC2021 |
TgraphExamples
Contents
- Some Layout tools
- Tgraphs for 7 vertex types
- Further Basic Tgraphs
- Some Simple Figures
- Figures for 7 vertex types
- Partial Composition figures
- Forced Tgraph figures
- Removed faces (forcing and composing)
- Incorrect Tgraphs
- superForce Figure
- Tgraphs with Boundary faces
- Boundary coverings and empires
- Emplace Choices
Description
Synopsis
- padBorder :: OKBackend b => Diagram b -> Diagram b
- chunks :: Int -> [a] -> [[a]]
- arrangeRowsGap :: OKBackend b => Double -> Int -> [Diagram b] -> Diagram b
- arrangeRows :: OKBackend b => Int -> [Diagram b] -> Diagram b
- labelAt :: OKBackend b => Point V2 Double -> String -> Diagram b -> Diagram b
- sunGraph :: Tgraph
- jackGraph :: Tgraph
- kingGraph :: Tgraph
- queenGraph :: Tgraph
- aceGraph :: Tgraph
- deuceGraph :: Tgraph
- starGraph :: Tgraph
- kiteGraph :: Tgraph
- dartGraph :: Tgraph
- fool :: Tgraph
- foolD :: Tgraph
- foolDminus :: Tgraph
- foolDs :: [Tgraph]
- sunDs :: [Tgraph]
- kiteDs :: [Tgraph]
- dartDs :: [Tgraph]
- dartD4 :: Tgraph
- sun3Dart :: Tgraph
- foolFig :: OKBackend b => Diagram b
- foolAndFoolD :: OKBackend b => Diagram b
- figSunD3D2 :: OKBackend b => Diagram b
- vertexTypesFig :: OKBackend b => Diagram b
- forceVFigures :: OKBackend b => [Diagram b]
- pCompFig1 :: OKBackend b => Diagram b
- pCompFig2 :: OKBackend b => Diagram b
- pCompFig :: OKBackend b => Diagram b
- forceFoolDminus :: OKBackend b => Diagram b
- forceDartD5Fig :: OKBackend b => Diagram b
- forceKiteD5Fig :: OKBackend b => Diagram b
- forceSunD5Fig :: OKBackend b => Diagram b
- forceFig :: OKBackend b => Diagram b
- brokenDart :: Tgraph
- badlyBrokenDart :: Tgraph
- brokenDartFig :: OKBackend b => Diagram b
- badlyBrokenDartFig :: OKBackend b => Diagram b
- removeIncompletesFig :: OKBackend b => Diagram b
- mistake :: Tgraph
- mistake1 :: Tgraph
- superForceFig :: OKBackend b => Diagram b
- superForceRocketsFig :: OKBackend b => Diagram b
- boundaryFDart4 :: Tgraph
- boundaryFDart5 :: Tgraph
- boundaryFDart4Fig :: OKBackend b => Diagram b
- boundaryFDart5Fig :: OKBackend b => Diagram b
- boundaryGapFDart4 :: Tgraph
- boundaryGapFDart5 :: Tgraph
- boundaryGap4Fig :: OKBackend b => Diagram b
- boundaryGap5Fig :: OKBackend b => Diagram b
- boundaryVCoveringFigs :: OKBackend b => Forced BoundaryState -> [Diagram b]
- boundaryECoveringFigs :: OKBackend b => Forced BoundaryState -> [Diagram b]
- kingECoveringFig :: OKBackend b => Diagram b
- kingVCoveringFig :: OKBackend b => Diagram b
- kingEmpiresFig :: OKBackend b => Diagram b
- kingEmpire1Fig :: OKBackend b => Diagram b
- kingEmpire2Fig :: OKBackend b => Diagram b
- emplaceChoices :: Tgraph -> [Tgraph]
- emplaceChoicesFig :: OKBackend b => Diagram b
Some Layout tools
padBorder :: OKBackend b => Diagram b -> Diagram b Source #
used for most diagrams to give border padding
arrangeRowsGap :: OKBackend b => Double -> Int -> [Diagram b] -> Diagram b Source #
arrangeRowsGap s n diags - arranges diags into n per row, centering each row horizontally, with a seperation gap (horizontally and vertically) of s. The result is a single diagram.
arrangeRows :: OKBackend b => Int -> [Diagram b] -> Diagram b Source #
arrangeRows n diags - arranges diags into n per row, centering each row horizontally. The result is a single diagram (seperation is 1 unit vertically and horizontally).
labelAt :: OKBackend b => Point V2 Double -> String -> Diagram b -> Diagram b Source #
add a given label at a given point offset from the centre of the given diagram.
Tgraphs for 7 vertex types
queenGraph :: Tgraph Source #
Tgraph for vertex type queen.
deuceGraph :: Tgraph Source #
Tgraph for vertextype deuce.
Further Basic Tgraphs
foolDminus :: Tgraph Source #
foolDminus: 3 faces removed from foolD - still a valid Tgraph
A sun with 3 darts on the boundary NOT all adjacent (Used in superForceRocketsFig).
Some Simple Figures
foolAndFoolD :: OKBackend b => Diagram b Source #
diagram of fool with foolD.
figSunD3D2 :: OKBackend b => Diagram b Source #
Figure for a 3 times decomposed sun with a 2 times decomposed sun.
Figures for 7 vertex types
vertexTypesFig :: OKBackend b => Diagram b Source #
vertexTypesFig is 7 vertex types in a single diagram as a row.
forceVFigures :: OKBackend b => [Diagram b] Source #
forceVFigures is a list of 7 diagrams - force of 7 vertex types.
Partial Composition figures
pCompFig1 :: OKBackend b => Diagram b Source #
diagram showing partial composition of a forced 3 times decomposed dart (with remainder faces in pale green).
pCompFig2 :: OKBackend b => Diagram b Source #
diagram showing partial composition of a forced 3 times decomposed kite (with remainder faces in pale green).
pCompFig :: OKBackend b => Diagram b Source #
diagram showing two partial compositions (with remainder faces in pale green).
Forced Tgraph figures
forceFoolDminus :: OKBackend b => Diagram b Source #
diagram of foolDminus and the result of forcing.
forceDartD5Fig :: OKBackend b => Diagram b Source #
diagram of forced 5 times decomposed dart.
forceKiteD5Fig :: OKBackend b => Diagram b Source #
diagram of forced 5 times decomposed kite.
forceSunD5Fig :: OKBackend b => Diagram b Source #
diagram of forced 5 times decomposed sun.
forceFig :: OKBackend b => Diagram b Source #
diagram of forced 5 times decomposed dart (left) and kite (right).
Removed faces (forcing and composing)
brokenDart :: Tgraph Source #
brokenDart is a 4 times decomposed dart (dartD4) with 5 halftile faces removed. Forcing will repair to produce the same Tgraph as force dartD4. This graph can also be repeatedly composed (without forcing) to get a maximal Tgraph.
badlyBrokenDart :: Tgraph Source #
badlyBrokenDart has more faces removed from brokenDart. This will also get repaired by forcing (to produce the same as force dartD4). However it will fail to produce a valid Tgraph if composed twice without forcing.
brokenDartFig :: OKBackend b => Diagram b Source #
brokenDartFig shows the faces removed from dartD4 to make brokenDart and badlyBrokenDart.
badlyBrokenDartFig :: OKBackend b => Diagram b Source #
badlyBrokenDartFig shows badlyBrokenDart, followed by its composition, followed by the faces that would result from an unchecked second composition which are not tile-connected. (Simply applying compose twice to badlyBrokenDart will raise an error).
removeIncompletesFig :: OKBackend b => Diagram b Source #
figure showing the result of removing incomplete tiles (those that do not have their matching halftile) to a 3 times decomposed sun.
Incorrect Tgraphs
mistake is a legal but incorrect Tgraph - a kite with 2 darts on its long edges
mistake1 is a kite bordered by 2 half darts (subgraph of mistake and still incorrect)
superForce Figure
superForceFig :: OKBackend b => Diagram b Source #
Diagram showing superForce with initial Tgraph g (red), force g (red and black), and superForce g (red and black and blue).
superForceRocketsFig :: OKBackend b => Diagram b Source #
Diagram showing 4 rockets formed by applying superForce to successive decompositions of sun3Dart. The decompositions are in red with normal force additions in black and superforce additions in blue.
Tgraphs with Boundary faces
boundaryFDart4 :: Tgraph Source #
graph of the boundary faces only of a forced graph (dartDs!!4)
boundaryFDart5 :: Tgraph Source #
graph of the boundary faces only of a forced graph (dartDs!!5)
boundaryFDart4Fig :: OKBackend b => Diagram b Source #
figure of the boundary faces only of a forced graph (dartDs!!4).
boundaryFDart5Fig :: OKBackend b => Diagram b Source #
figure of the boundary faces only of a forced graph (dartDs!!5).
boundaryGapFDart4 :: Tgraph Source #
graph of the boundary faces only of a forced graph - with extra faces removed to make a gap
boundaryGapFDart5 :: Tgraph Source #
graph of the boundary faces only of a forced graph - with extra faces removed to make a gap
boundaryGap4Fig :: OKBackend b => Diagram b Source #
figure for the boundary gap graph boundaryGapFDart4.
boundaryGap5Fig :: OKBackend b => Diagram b Source #
figure for the boundary gap graph boundaryGapFDart5.
Boundary coverings and empires
boundaryVCoveringFigs :: OKBackend b => Forced BoundaryState -> [Diagram b] Source #
boundaryVCoveringFigs bd - produces a list of diagrams for the boundaryVCovering of bd (with the Tgraph represented by bd shown in red in each case).
boundaryECoveringFigs :: OKBackend b => Forced BoundaryState -> [Diagram b] Source #
boundaryECoveringFigs bd - produces a list of diagrams for the boundaryECovering of bd (with the Tgraph represented by bd shown in red in each case).
kingECoveringFig :: OKBackend b => Diagram b Source #
diagram showing the boundaryECovering of a forced kingGraph.
kingVCoveringFig :: OKBackend b => Diagram b Source #
diagram showing the boundaryVCovering of a forced kingGraph.
kingEmpiresFig :: OKBackend b => Diagram b Source #
figure showing King's empires (1 and 2).
kingEmpire1Fig :: OKBackend b => Diagram b Source #
figure showing King's empires 1.
kingEmpire2Fig :: OKBackend b => Diagram b Source #
figure showing King's empire 2.
Emplace Choices
emplaceChoices :: Tgraph -> [Tgraph] Source #
emplaceChoices forces then maximally composes. At this top level it produces a list of forced choices for each of the unknowns of this top level Tgraph. It then repeatedly applies (force . decompose) back to the starting level to return a list of Tgraphs. This version relies on compForce theorem and related theorems
emplaceChoicesFig :: OKBackend b => Diagram b Source #
Example showing emplaceChoices for foolD with foolD shown in red in each choice