-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Description
For a tall rectangular matrix the qr decomposition returns an error.
Example:
import numpy as np
import xprec
import xprec.linalg
A = np.random.rand(3,2)
A = A.astype(xprec.ddouble)
Q, R = xprec.linalg.qr(A)
This seems to be due to wrong dimensions in https://github.com/tuwien-cms/xprec/blob/40189e4c2e07e434726278d16108bac3d6ccb9b9/pysrc/xprec/linalg.py#L32C1-L32C34
It most likely should be Q = np.zeros((m, k), A.dtype) instead of Q = np.zeros((k, m), A.dtype). Also compare with the truncated qr decomposition rrqr for which this error doesn't occur.
Metadata
Metadata
Assignees
Labels
No labels