TABULA/samples/inversion test

From J Wiki
Jump to navigation Jump to search

This is SAMPLE4. To work with this sample, enter $4

inversion test
    ┌ ┌ ┌ ┌ ┌ ┌ ┌ ┌ ┌ {1}        3 m   X[1]
┌ ┌ ├ ├ │ │ ├ ├ ├ ├ │ {2}        5 m   X[2]
│ │ │ │ │ │ ├ │ ├ │ │ {3}        2 m   X[3]
│ │ │ │ │ │ │ │ │ │ └>{4}    9.425 m   PI * X[1]
│ │ │ │ │ │ │ │ │ └>  {5}        8 m   X[1]+X[2]
│ │ │ │ │ │ │ │ └>    {6}       10 m   X[1]+X[2]+X[3]
│ │ │ │ │ │ │ └>      {7}       15 m²  X[1]*X[2]
│ │ │ │ │ │ └>        {8}       30 m³  X[1]*X[2]*X[3]
├ ├ │ │ │ └>          {9}        9 m²  X[1]^2
│ │ │ │ └>            {10}   0.333 /m  1/X[1]
│ │ │ └>              {11}   0.600 /   X[1] / X[2]
│ │ └>                {12}   1.667 /   X[2] / X[1]
│ └>                  {13}   0.556 /m  X[2] / (X[1]^2)
└>                    {14}   1.800 m   (X[1]^2) / X[2]

Rationale

When backfitting values, TABULA takes short cuts, trying out simple inversion heuristics before deploying the most general method.

This t-table is a testbed for such heuristics. It is offered as a factory sample to show you what backfitting can do.

Note particularly how a change to a given computed line will not only change the line(s) it depends on, but all other lines which depend on these changed lines.

When you overtype a computed value, TABULA builds an internal tree of values it must change in consequence. But this tree depends on the line you choose to overtype.

Try it out

  1. Select item {8}
  2. Click tool addpc
    This increases the value of {8} by 1%
  3. Note what changes, viz. all items change via the backfit made to {1}, {2}, {3}.
  4. Reload the sample and repeat the above steps. This time try holding one (or more) of the ancestors {1}, {2}, {3}.
    Instead of reloading, click Undo (multiple times).

This exercises the heuristic addressed by {9}. To exercise a different heuristic, choose another item: {4} to {14}.