Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Point Helper Reference

Point helpers turn the geometry you have already cut into reusable coordinates. They power angle + point cuts, point-pair slices, macros, and optimizer targets. Every helper resolves to a 3D point once the referenced tiers exist.

Center point (cp)

cp sits on the stone's centre axis. It always returns (0, 0, 1) when the active side is the crown (up) and (0, 0, -1) when the active side is the pavilion (down).

set name "Center Anchors"

// Mark the culet to check alignment
show cp blue
P1 down 0 @ 41 : cp x8
P1
Centerpoint

Girdle points (gp)

gp scans the vertical girdle facets and returns the vertex that sits “in front” of the requested index/angle. Inside a cut command it borrows the current index/angle automatically; elsewhere you must supply at(index, angle) (angle optional) so the helper knows where to search.

set name "Girdle Pickup"
set gear 96

P1 0 @ 45 : cp x8
G1 0 @ 90 : size x16
C1 6 @ 34 : MP(P1,G1) + girdle x16

show gp at (0) cyan
show gp at (24) orange
C1
Girdle Point Top View
G1P1
Girdle Point Side View

For uneven girdle lines, there is some extra logic that decides if a point can be a true girdle point. If this fails for some reason, the user can use the mp() function, explained next.

Meet points (mp)

mp searches for the intersection of tiers you name. Pass one or more tiers to include, prefix a tier with ! to exclude it, and ProFacet finds the point that satisfies all of the remaining facets on the current side.

Because mp respects the current index and angle context, you can add at (explained later) to jump directly to a specific tooth.

Matching tiers vs. explicit indices

Think of mp as a facet filter: every positive tier you list must participate in the actual meet, while negated tiers must be absent. There are often several equivalent ways to describe the same vertex.

// A few common patterns
mp(C1)                 // single-tier meet
mp(C1, G1)             // multiple tiers
mp(C1, C1)             // requires C1 to be part of the meet twice
mp(C1, G1, !C2)        // exclude an unwanted tier
mp(C1:12, C2:16)       // insist on specific cut indices
mp(C1) at (3, 45.0)    // explicit tooth/angle override

Symmetry means those filters can match multiple physical points. That’s usually fine inside a facet command because the base index and angle narrow the choice. Outside of a cut—show mp(C1) or let helper = mp(G1)—add an at(index, angle) clause to keep things deterministic:

Relying on explicit indices ties the design to a particular gear/symmetry combination, so prefer tier filters when you can.

Examples

set name "Meetpoint Examples"
set gear 96

P1 3 @ 41.0 : cp xx 8
G1 3 @ 90.0 : size
P2 0 @ 39.8 : gp
C1 3 @ 50.0 : mp(P1, P2) +girdle
C2 0 @ 38.0 : gp
C3 6 @ 26.0 : mp(C1)
T 0 @ 0 : mp(C2) x1

show mp(C1) green
show mp(C2) blue
show mp(C1, G1) purple
show mp(C1, C1, !C2) orange
show mp(P1, P2, P2) red
C1C2G1P1P2
mp() examples

Edge references (edge)

edge returns the shared edge between two previously cut facets. You pass tier/index pairs (edge(C1:0, C1:6)), and the helper returns both endpoints so other helpers can work with them.

C1 up 0 @ 32 : 0.08 x16
let long_edge, _ = edge(C1:0, C1:6)

Use edge only after both referenced facets exist; otherwise the interpreter raises an error telling you which tier/index is missing.

Edge interpolation (ep)

ep walks along an edge or between two arbitrary points. Supply either edge(...) plus a factor between 0.0 and 1.0, or two point helpers and the factor. Zero sticks to the first point, one sticks to the second, and any other value interpolates in between.

set name "Edge Interpolation"

C1 up 0 @ 32 : 0.08 x16

let girdle_start, girdle_end = edge(C1:0, C1:6)
let mid_edge = ep(girdle_start, girdle_end, 0.5)

show up mid_edge cyan
C2 up 0 @ 32 : mid_edge + girdle x16

ep(mp(...), mp(...), 0.25) is equally valid when you want a point partway between two meetpoints.

Projected crossover (fred)

fred solves more complex intersections—ideal when the optimizer needs a reference that depends on multiple moving parts. Conceptually it projects two line segments onto the XY plane, finds their intersection, then lifts that XY intersection back onto one of the original segments. The helper was named in honor of Fred Van Sant—one of the most inventive gem designers the lapidary world has ever seen—whose many masterpieces lean on these projected crossings to stay perfectly stitched together.

  • fred(p1, p2, p3, p4) intersects the XY projections of p1–p2 with p3–p4 and returns the point that lives along the p3–p4 segment.
  • fred(p1, p2, edge(F1, F2)) is shorthand that uses the shared edge between F1 and F2 for the second segment.
set name "Fred Demo"

P1 down 0 @ 41.8 : 0.18 x8
P2 down 12 @ 40.0 : mp(P1) x8
G1 0 @ 90 : size x16
T up 0 @ 0 : cp x16

let culet = cp
let table = cp
let bridge = fred(culet, table, edge(G1:0, G1:6))

show bridge magenta

This helper is crucial for elaborate patterns such as Honeycomb FVS or Round Trichecker-1, where you have to drop points onto the exact crossover of two projected paths without breaking symmetry.

Projection workflow for the fred helper
Visualizing the `fred` projection workflow

Projected reference (prz)

prz drops an existing point onto either a reference line or an existing facet. It mirrors the projection math used by fred, but instead of intersecting two lines it projects the target straight to the chosen guide and returns the corresponding 3D point.

  • prz(p_target, line_start, line_end) works with any combination of point helpers or variables that resolve to points and projects in the XY plane (so the projected point can fall outside the original segment if your geometry demands it).
  • prz(p_target, facet_ref) uses a facet reference such as P1:12 and projects onto the live plane of that facet. The facet must already exist in the current geometry—the interpreter will raise a clear error if it has been cut away or is degenerate.
set name "Projected Reference"
set gear 96

P1 down 0 @ 41.8 : 0.18 x8
G1 0 @ 90 : size x16
C1 6 @ 34 : mp(P1, G1) + girdle x16

let rail_start = mp(G1)
let rail_end = mp(G1) at (6)
let culet = mp(P1)

let drop = prz(culet, rail_start, rail_end)
show drop orange

Use prz to pin decorative girdle cuts or checkerboard overlays to a reference rail without introducing extra tiers purely to feed edge(...), or to drop an exploratory helper directly onto an existing facet plane with prz(mp(G1), P1:12) when you just need a quick reference on that surface.

Index and Angle override (at)

at is a trailing clause—not a separate function—that pins a helper to a specific index and optional angle: mp(P1) at (12, 39.4). The first number is the index (integer), and the second is the angle override. If you omit the angle (mp(P1) at (12)), the helper keeps the current angle context.

set name "Attachments"
set gear 96

P1 0 @ 41.5 : 0.18 x8

let tooth_12 = mp(P1) at (12, 41.5)
show tooth_12 green

C1 0 @ 32.2 : tooth_12 + girdle x8