Skip to content

Add Octave cross-check harness under bench/octave - #72

Merged
crertel merged 1 commit into
masterfrom
octave-cross-check
Sep 16, 2026
Merged

crertel merged 1 commit into
masterfrom
octave-cross-check

Conversation

@crertel

@crertel crertel commented Sep 16, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds bench/octave/: an independent numerical cross-check of every public function in Vec2, Vec3, Vec4, Mat22, Mat33, Mat44, and Quatern against GNU Octave.
  • gen_cases.exs drives each function with seeded random inputs plus documented error/edge cases and writes an Octave data file; check.m recomputes each result from the documented conventions (row-major tuples, row-vector transforms, right-handed rotations, OpenGL depth range, Hamilton product on {w,x,y,z}) and reports per-function max error.
  • run.sh runs both steps. Requires mix and octave-cli on PATH.

Current result on master (3.0.0): 1365 cases, zero mismatches, worst error ~3e-15. No library code is changed.

Test plan

  • bench/octave/run.sh completes with no FAIL/MISMATCH lines

🤖 Generated with Claude Code

Generates seeded random and documented edge cases for every public
function in Vec2, Vec3, Vec4, Mat22, Mat33, Mat44, and Quatern, then
recomputes each result in GNU Octave from the documented conventions
and reports per-function maximum error.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — octave-cross-check into master

4 similar comments
@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — octave-cross-check into master

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — octave-cross-check into master

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — octave-cross-check into master

@coveralls

Copy link
Copy Markdown

Coverage Status

coverage: 100.0%. remained the same — octave-cross-check into master

@crertel
crertel merged commit 4bd443e into master Sep 16, 2026
4 checks passed
@crertel
crertel deleted the octave-cross-check branch September 16, 2026 18:00
@crertel crertel mentioned this pull request Sep 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants