Skip to content

Commit 1819eee

Browse files
lkdvosclaude
andcommitted
docs: update the test README for the matrixfunctions group
The README added in #262 describes the layout this branch changes: the matrix exponential has moved out of `common`, the `genericschur` and `genericlinearalgebra` groups are gone now that each driver covers the generic element types alongside the BLAS floats, and `matrixfunctions` is a new group. Also records why the `eig`-based algorithms have to name their driver explicitly for those element types, and lists the spectrum-controlled instantiators the matrix functions need. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 9c3fd6c commit 1819eee

1 file changed

Lines changed: 13 additions & 3 deletions

File tree

test/README.md

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,18 @@ file placed directly in `test/` would belong to no group and never run in CI.
7373

7474
| Group | Contents |
7575
|-------|----------|
76-
| `common` | Algorithm selection and defaults, truncation strategies, projections, matrix exponential, Aqua code-quality checks |
76+
| `common` | Algorithm selection and defaults, truncation strategies, projections, Aqua code-quality checks |
7777
| `decompositions` | `qr`, `lq`, `svd`, `eig`, `eigh`, `gen_eig`, `schur`, `polar`, `orthnull` on CPU and GPU array types |
78+
| `matrixfunctions` | `exponential`, `squareroot`, `logarithm`, `power` on CPU and GPU array types |
7879
| `chainrules` | ChainRulesCore rules, exercised through ChainRulesTestUtils and Zygote |
7980
| `mooncake` | Mooncake AD rules |
8081
| `enzyme` | Enzyme AD rules, exercised through EnzymeTestUtils |
81-
| `genericlinearalgebra` | `MatrixAlgebraKitGenericLinearAlgebraExt` |
82-
| `genericschur` | `MatrixAlgebraKitGenericSchurExt` |
82+
83+
The generic element types (`BigFloat` and friends) are not a group of their own: each driver covers
84+
them alongside the BLAS floats, naming the `MatrixAlgebraKitGenericSchurExt` and
85+
`MatrixAlgebraKitGenericLinearAlgebraExt` algorithms explicitly. Both extensions are loaded at once,
86+
so a bare `QRIteration()` resolves its driver to GenericLinearAlgebra, which provides no `geev!`;
87+
`eig`-based algorithms therefore have to spell out `QRIteration(; driver = GS())`.
8388

8489
Two directories are *not* groups: `testsuite/` holds the shared implementation described below and
8590
is excluded both from discovery (in `runtests.jl`) and from CI (`exclude: '["testsuite"]'`).
@@ -125,6 +130,11 @@ Supporting infrastructure in the module:
125130
- Predicates used throughout the assertions: `isleftnull`, `isrightnull`, `isleftcomplete`,
126131
`isrightcomplete`, `has_positive_diagonal`.
127132
- `instantiate_unitary`, `instantiate_rank_deficient_matrix` — inputs with prescribed structure.
133+
- `instantiate_smallnorm_matrix`, `instantiate_offaxis_matrix`, `instantiate_posdef_matrix`,
134+
`instantiate_hermitian_spectrum` — inputs with a prescribed *spectrum*, which the matrix functions
135+
need: `squareroot`, `logarithm` and fractional `power` are only defined away from the negative
136+
real axis, and `logarithm` also requires a nonzero spectrum, so the plain `randn` of
137+
`instantiate_matrix` will not do.
128138

129139
`test/linearmap.jl` is a further helper, defining a `LinearMap` wrapper that is deliberately *not* an
130140
`AbstractMatrix`, used to check the generic code paths. It is excluded from discovery and included

0 commit comments

Comments
 (0)