Commit 39a31ca
committed
Fix SafeLeftDivide for rank-0 module inputs
Singular.lift misbehaves when A has 0 rows or B has 0 columns,
returning matrices with wrong shapes. Add early returns:
- nrows(A)==0: system has 0 equations, trivial solution X = 0_{c×s}
- ncols(B)==0: RHS is empty, solution must also be empty X = 0_{c×0}
In both cases X = zero_matrix(R, ncols(A), ncols(B)).
Bump version to v0.1.111 parent 7077a58 commit 39a31ca
2 files changed
Lines changed: 9 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1047 | 1047 | | |
1048 | 1048 | | |
1049 | 1049 | | |
| 1050 | + | |
| 1051 | + | |
| 1052 | + | |
| 1053 | + | |
| 1054 | + | |
| 1055 | + | |
| 1056 | + | |
| 1057 | + | |
1050 | 1058 | | |
1051 | 1059 | | |
1052 | 1060 | | |
| |||
0 commit comments