Example diagrams
These are all the currently working program triples for our new system. (These are mostly taken from the first sample, though some may not look exactly like the image since they are from old versions of the system.)
A registry of all examples can be found in our repository at packages/examples/src/registry.json
.
NOTE: If you're wondering why there are so few examples, it's because we recently did a big port of the system from Haskell to Typescript, deprecating all the examples shown in the SIGGRAPH '20 paper. The paths to reproduce those diagrams are archived here. Be warned that they no longer are guaranteed to work on the most recent version of the master
branch, though most of them should be quite easy to port to Typescript!
- Orthogonal vector example from paper:
penrose linear-algebra-domain/twoVectorsPerp-unsugared.sub linear-algebra-domain/linear-algebra-paper-simple.sty linear-algebra-domain/linear-algebra.dsl
- Two sets with labels:
penrose set-theory-domain/twosets-simple.sub set-theory-domain/venn-small.sty set-theory-domain/setTheory.dsl
- Nested: [currently broken due to NaNs]
roger watch nested.sub venn.sty setTheory.dsl
https://www.dropbox.com/s/mjasajy55b6kozx/Screen%20Shot%202021-02-25%20at%208.12.26%20PM.png?dl=0
- Big set example with circles:
penrose set-theory-domain/tree.sub set-theory-domain/venn.sty set-theory-domain/setTheory.dsl
- Big set example with tree:
penrose set-theory-domain/tree.sub set-theory-domain/tree.sty set-theory-domain/setTheory.dsl
- 3D set example:
penrose set-theory-domain/tree.sub set-theory-domain/venn-3d.sty set-theory-domain/setTheory.dsl
- Continuous map:
penrose set-theory-domain/continuousmap.sub set-theory-domain/continuousmap.sty set-theory-domain/setTheory.dsl
- Hyperbolic:
penrose hyperbolic-domain/hyperbolic-example-unsugared.sub hyperbolic-domain/PoincareDisk.sty hyperbolic-domain/hyperbolic.dsl
- Geometry (partial):
penrose geometry-domain/pythagorean-theorem-unsugared.sub geometry-domain/euclidean.sty geometry-domain/geometry.dsl
- Sets (optimizing thru computation):
penrose set-theory-domain/multisets.sub set-theory-domain/venn-comp-test.sty set-theory-domain/setTheory.dsl
- Cross-domain mesh-set example:
penrose mesh-set-domain/DomainInterop-unsugared.sub mesh-set-domain/DomainInterop.sty mesh-set-domain/DomainInterop.dsl
- Graphs:
roger watch graph-domain/graph1.sub graph-domain/graph-theory.sty graph-domain/graph-theory.dsl
Run: npx roger watch molecules/glutamine.sub molecules/molecules-basic.sty molecules/molecules.dsl
For more complicated example try molecules/caffeine.sub
.
Alternative styles:
molecules/molecules.sty
molecules/molecules-elegant.sty
Run: npx roger watch logic-circuit-domain/half-adder.sub logic-circuit-domain/distinctive-shape.sty logic-circuit-domain/logic-gates.dsl
For more complicated example try logic-circuit-domain/full-adder.sub
.
- Disjoint rectangles, contained:
roger watch graph-domain/small-graph.sub graph-domain/disjoint-rects.sty graph-domain/graph-theory.dsl
- Disjoint rectangles, contained within a large canvas (1600x1200):
roger watch graph-domain/small-graph.sub graph-domain/disjoint-rects-large-canvas.sty graph-domain/graph-theory.dsl
- Disjoint rectangles, contained within a small canvas (400x300):
roger watch graph-domain/small-graph.sub graph-domain/disjoint-rects-small-canvas.sty graph-domain/graph-theory.dsl
- Disjoint rectangles and horizontal lines, contained:
roger watch graph-domain/small-graph.sub graph-domain/disjoint-rect-line-horiz.sty graph-domain/graph-theory.dsl
- Very basic monoidal categories:
roger watch monoidal-category-domain/test.sub monoidal-category-domain/monoidal-test.sty monoidal-category-domain/monoidal-test.dsl
Found a problem or got a suggestion? Please open a GitHub issue and tag it with documentation
!