Docs + @c completion: doccords for cplx/eig, and @ch/@cq (half/quad) complex#49
Merged
Conversation
Reformats the comments on the public-facing arms added in the %cplx (#46), symmetric-eig (#47), and Hermitian-eig (#48) work into the canonical Lagoon/Saloon format: +name signature, one-line description, Examples, Source. Internal helpers keep their terse comments (matching how lagoon already treats fun-scalar/get-col). Arms documented: /lib/complex (cs door): re im pak zero one add sub neg conj mul div abs equ neq -- examples transcribed from tests/lib/complex. cd gets a door-level doccord pointing at cs (verbatim @rd/@cd analogue). lagoon: conj, dotc -- examples from tests/lib/lagoon-cplx. saloon: eig, eigvals, eigvecs -- eigenvalue outputs captured from the ship. Comment-only; all three libs still build. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Per review: give the cd door full per-arm doccords (not a pointer to cs), and add the test coverage those examples should have had. tests/lib/complex now exercises every public arm for BOTH doors -- re/im/pak/zero/one/add/sub/neg/ conj/mul/div/abs/equ/neq -- with values captured from the ship (cd) and from NumPy (cs). All 8 cases pass; the cd doccord examples are now test-backed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two related things, in order:
Canonical doccords for the public arms added in the
%cplx/eig work —+name:signature → description →Examples→Source— on/lib/complex(cs/cd), lagoonconj/dotc, and salooneig/eigvals/eigvecs. Internal helpers keep terse comments.cdis fully duplicated (not pointed atcs), andtests/lib/complexnow exercises every public arm for both doors.Completes the
@caura family — implements@ch(half) and@cq(quad), the two slots reserved in/lib/complex's header, end to end across all three layers.@ch/@cq— what landed/lib/complexch(2×@rh) andcq(2×@rq) doors — verbatim analogues ofcs/cd— with full doccords + complete tests; all values captured from the ship%cplxch) / 8 (cq) intoeye/ones/fun-scalar/trans-scalar(previously 6/7 only); element-wise ops +lagoon-cplxch/cq testseigcb-comp→(dec cb); float helpers cover component bloq 4–7 (rh/rs/rd/rq), complex helpers cover bloq 5–8 (ch/cs/cd/cq);eig-hermaccepts%cplx5–8 and symmetriceigaccepts%i7544–7Eigendecomposition now runs at half through quad precision. New
saloon-eigh-cctest verifies[[2,i],[−i,2]] → {1,3}at@chand@cq(the analytic case, since NumPy can't emit true IEEE binary128).Tests
/tests/lib/complex: 16 cases (cs/cd/ch/cq × components/arith/unary/compare) — all green./tests/lib/lagoon-cplx: +ch/+cq element-wise — green./tests/lib/saloon-eigh(cs/cd) +saloon-eigh-cc(ch/cq) — green, no regression.🤖 Generated with Claude Code