-
Notifications
You must be signed in to change notification settings - Fork 6
Description
Summary
We should have an option to add an initial guess (for iterative refinement or regular iterative solve).
If there is an initial guess
We then solve
An ideal implementation is one where we have the same function name and it can take either two arguments (
Rationale
Right now, when we use an iterative solver directly, we have no option of supplying an initial guess. When we use it for iterative refinement, we use an initial guess in a way that is less numerically accurate.
Description
Some features to make this complete:
- Check if
$|b|_2</code><<code>|b-Ax|_2$ . If it is, warn the user that their initial guess is worse than all 0s and ignore that initial guess. - If a nonzero guess was supplied, check if
$|b-Ax-Ay|_2</code>><code>|b-Ax|_2$ . Note that the order of subtraction is important for the left side. If it is, warn the user that the iterative solver was not able to find a solution better than the initial guess, and output$x$ (not$x+y$ ). For iterative refinement, this corresponds to not improving upon the direct solve.
Additional information
No response