tri
tri is tr with an index progression in place of the region. The i means the command takes a progression. It does not mean inverse.
Syntax
tri i_list ; j_list ; k_list ; operator [ operator ... ] ;
A progression is three lists, one for i, one for j and one for k, each ending in ;. Inside a progression a 0 separates unions and never means an extreme. The operators are the thirteen of tr, and the list of operators ends in ;. The concepts chapter explains progressions.
What it does
tri applies the transformation to the vertices of every region the progression expands to. It is tr for each of those regions, and tr describes the transformation. A vertex that lies in more than one of the regions is transformed once, so an overlap does not rotate a vertex twice.
When James applies it
As tr: step 1iii of the hierarchy, in input order within the step. tri is legal only in the Part phase.
Rules James adds
- A vertex reached by several of the expanded regions is transformed once.
- A progression that expands to no region warns (E0107) and the command is ignored.
- The operators James refuses for
trare refused here.
Diagnostics
- E0500: a region the progression expands to lies outside the part.
- E0503: an operator is unknown, malformed or one of the five refused.
- E0504:
raxishas a direction of zero length. - E0101: a list holds one positive number, which selects nothing.
- E0103: an interval is written high to low.
- E0107: the progression expands to no region.
Example
The script tests/corpus/170-tri-translates-edges/input.tg, which make test runs:
c tri moves two edges along i by 0.5 in x; the pinned j and k choose them.
block 1 3 5;1 3;1 3;0 1 2;0 1;0 1;
tri 1 3;-1 0 -2;-1;mx 0.5;
endpart
The progression 1 3;-1 0 -2;-1; spans reduced i 1 to 3 and pins j at 1 and at 2 and k at 1. James expands it to two edges, 1 1 1 3 1 1 and 1 2 1 3 2 1, and shows both in the IR with one transformation row, mx 0.5. The mesh has the nodes of both edges moved 0.5 in x.