Symptom
A P2 field set to x^2 + 3xy - y (which P2 represents exactly) is evaluated with uw.function.evaluate (serial) at every P2 node moved a fixed distance in a random direction, six directions per node, on UnstructuredSimplexBox(cellSize=0.1):
| offset |
points |
max error |
points off by more than 1e-10 |
| 1.5e-3 |
11838 |
2.7e-5 |
20 |
| 3e-3 |
11838 |
3.9e-5 |
13 |
| 6e-3 |
11838 |
3.8e-5 |
4 |
| 1e-2 |
11838 |
1.0e-5 |
2 |
| 2e-2 |
11838 |
1.7e-5 |
3 |
Any cell's polynomial gives the exact value, so a correct evaluation is exact to round-off wherever the point is located; a few points take a different value. The same points are off in parallel (global_evaluate, np 4) by the same amounts, so this is the serial evaluation, not the parallel routing. Candidate: the face-slab locator (_EVAL_FACE_TOL = 1e-2) and the reference-coordinate clamp, or the exterior (rbf) path taking points it should not.
Reproduction
~/+Simulations/forward_nodes/strand_scan.py (serial: python strand_scan.py).
Underworld development team with AI support from Claude Code
Symptom
A P2 field set to x^2 + 3xy - y (which P2 represents exactly) is evaluated with
uw.function.evaluate(serial) at every P2 node moved a fixed distance in a random direction, six directions per node, onUnstructuredSimplexBox(cellSize=0.1):Any cell's polynomial gives the exact value, so a correct evaluation is exact to round-off wherever the point is located; a few points take a different value. The same points are off in parallel (
global_evaluate, np 4) by the same amounts, so this is the serial evaluation, not the parallel routing. Candidate: the face-slab locator (_EVAL_FACE_TOL = 1e-2) and the reference-coordinate clamp, or the exterior (rbf) path taking points it should not.Reproduction
~/+Simulations/forward_nodes/strand_scan.py(serial:python strand_scan.py).Underworld development team with AI support from Claude Code