Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

`lstsq(alg=:iterative)` blanket-rejects non-BLAS eltypes, yet the iterative engine works in BigFloat

Open
#13 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
72/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
julia
Domain
backend

Research direction

Start with _check_lstsq_eltype in src/lstsq.jl:30-41 and the iterative entry point in ext/...IterativeSolversExt.jl:22; compare how the three engines apply the guard. Add the requested Int-rejection and BigFloat iterative tests, then update the docstring/README so the BLAS-only limitation is clear for :dense and :structured; done means iterative BigFloat works while unsupported integer inputs remain rejected.

Written by the indexing model from the issue text.

Description

WHAT: _check_lstsq_eltype (src/lstsq.jl:30-41) is called by all three engines, including iterative (ext/...IterativeSolversExt.jl:22). But the iterative engine uses only the structured matvec/adjoint + IterativeSolvers.lsqr/lsmr — none need BLAS floats. Confirmed: a rank-deficient BigFloat A via lsqr converged to relerr 1.6e-15 vs the pinv oracle, yet lstsq(A, b; alg=:iterative) throws ArgumentError. WHY IT MATTERS: A real capability is needlessly suppressed — high-precision Newton in BVP solvers is the package's target regime. The guard is correct for :dense (LAPACK gelsy) but wrong for :iterative. FIX: Move the BLAS-float guard out of the shared entry into the dense/structured paths only; in the iterative engine check for real/complex AbstractFloat (still rejects Int/Rational, lets BigFloat/Complex{BigFloat}/Float16 through). Add the Int-rejection test plus a BigFloat iterative test. Update the docstring/README ('Only Float32/Float64/...'). Pairs with documenting that :structured/:dense are BLAS-float-only by design (the :structured SVD needs GenericLinearAlgebra) and directing generic-eltype users to :iterative. EFFORT: S.


Priority: medium. Filed from an automated next-steps audit of the QR/lstsq work (see PR #6).

Dominant language
Julia
Stars
0
Forks
1
Avg merge
23m
Merged PRs (30d)
3

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from SciML/SparseWithDenseRowColMatrices.jl

All issues in SciML/SparseWithDenseRowColMatrices.jl

Similar issues

More Julia issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.