Skip to content

Commit f2fe965

Browse files
authored
BlockArrays v1.0 + LazyArrays v2.0 (#171)
* Cholesky tests pass * Tests pass * blcolasts * PseudoBlock -> Blocked * Update infbanded.jl * Update Project.toml * Update ci.yml
1 parent 5857c95 commit f2fe965

File tree

14 files changed

+95
-79
lines changed

14 files changed

+95
-79
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,7 @@ jobs:
3737
fail-fast: false
3838
matrix:
3939
version:
40-
- '1.9'
41-
- '1'
40+
- '1.10'
4241
os:
4342
- ubuntu-latest
4443
- macOS-latest

Project.toml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name = "InfiniteLinearAlgebra"
22
uuid = "cde9dba0-b1de-11e9-2c62-0bab9446c55c"
3-
version = "0.7.6"
3+
version = "0.8"
44

55
[deps]
66
ArrayLayouts = "4c555306-a7a7-4459-81d9-ec55ddd5c99a"
@@ -19,22 +19,22 @@ SemiseparableMatrices = "f8ebbe35-cbfb-4060-bf7f-b10e4670cf57"
1919
[compat]
2020
Aqua = "0.8"
2121
ArrayLayouts = "1.9.2"
22-
BandedMatrices = "0.17.19, 1"
23-
BlockArrays = "0.16.14"
24-
BlockBandedMatrices = "0.12"
25-
FillArrays = "1"
22+
BandedMatrices = "1.0"
23+
BlockArrays = "1.0"
24+
BlockBandedMatrices = "0.13"
25+
FillArrays = "1.0"
2626
Infinities = "0.1"
27-
InfiniteArrays = "0.13"
28-
LazyArrays = "1.3"
29-
LazyBandedMatrices = "0.9"
27+
InfiniteArrays = "0.14"
28+
LazyArrays = "2.0"
29+
LazyBandedMatrices = "0.10"
3030
LinearAlgebra = "1"
31-
MatrixFactorizations = "2.2"
31+
MatrixFactorizations = "3.0"
3232
Random = "1"
33-
SemiseparableMatrices = "0.3"
33+
SemiseparableMatrices = "0.4"
3434
SpecialFunctions = "2"
3535
StaticArrays = "1"
3636
Test = "1"
37-
julia = "1.9"
37+
julia = "1.10"
3838

3939
[extras]
4040
Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595"

src/InfiniteLinearAlgebra.jl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@ import BandedMatrices: BandedColumns, BandedMatrix, BandedMatrix, _BandedMatrix,
2323
_BandedMatrix, _BandedMatrix, _banded_qr, _banded_qr!, _default_banded_broadcast, banded_chol!,
2424
banded_similar, bandedcolumns, bandeddata, bandwidths, bandwidths
2525

26-
import BlockArrays: AbstractBlockLayout, BlockLayout, BlockSlice, BlockSlice1, BlockedUnitRange,
27-
blockcolsupport, sizes_from_blocks
26+
import BlockArrays: AbstractBlockLayout, BlockLayout, BlockSlice, BlockSlice1, BlockedOneTo,
27+
blockcolsupport, sizes_from_blocks, OneToCumsum, AbstractBlockedUnitRange
2828

2929
import BlockBandedMatrices: AbstractBlockBandedLayout, BlockBandedMatrix, BlockSkylineMatrix,
3030
BlockSkylineSizes, BlockTridiagonal, _BlockBandedMatrix, _BlockSkylineMatrix,
@@ -38,12 +38,12 @@ import Infinities: InfiniteCardinal, Infinity
3838

3939
import LazyArrays: AbstractCachedMatrix, AbstractCachedVector, AbstractLazyLayout, ApplyArray, ApplyLayout, ApplyMatrix,
4040
CachedArray, CachedLayout, CachedMatrix, CachedVector, LazyArrayStyle, LazyLayout,
41-
LazyLayouts, LazyMatrix, PaddedLayout, _broadcast_sub_arguments,
41+
LazyLayouts, LazyMatrix, AbstractPaddedLayout, PaddedColumns, _broadcast_sub_arguments,
4242
applybroadcaststyle, applylayout, arguments, cacheddata, paddeddata, resizedata!, simplifiable,
4343
simplify
4444

4545
import LazyBandedMatrices: AbstractLazyBandedBlockBandedLayout, AbstractLazyBandedLayout, ApplyBandedLayout, BlockVec,
46-
BroadcastBandedLayout, KronTravBandedBlockBandedLayout, LazyBandedLayout, OneToCumsum,
46+
BroadcastBandedLayout, KronTravBandedBlockBandedLayout, LazyBandedLayout,
4747
_block_interlace_axes, _krontrav_axes, krontravargs
4848

4949
import LinearAlgebra: AbstractQ, AdjOrTrans, factorize, matprod, qr
@@ -103,7 +103,7 @@ resizes a vector `c` but in a way that block sizes are not changed when `c` has
103103
It may allocate a new vector in some settings.
104104
"""
105105
compatible_resize!(_, c::AbstractVector, n) = resize!(c, n)
106-
compatible_resize!(ax::BlockedUnitRange, c::AbstractVector, n) = resize!(c, iszero(n) ? Block(0) : findblock(ax, n))
106+
compatible_resize!(ax::BlockedOneTo, c::AbstractVector, n) = resize!(c, iszero(n) ? Block(0) : findblock(ax, n))
107107
compatible_resize!(c, n) = compatible_resize!(axes(c,1), c, n)
108108
chop!(c::AbstractVector{T}, tol::Real=zero(real(T))) where T = compatible_resize!(c, choplength(c, tol))
109109

@@ -128,7 +128,7 @@ pad(c, ax...) = PaddedArray(c, ax)
128128

129129
pad(c::Transpose, ax, bx) = transpose(pad(parent(c), bx, ax))
130130
pad(c::Adjoint, ax, bx) = adjoint(pad(parent(c), bx, ax))
131-
pad(c::BlockVec, ax::BlockedUnitRange{<:InfStepRange}) = BlockVec(pad(c.args[1], size(c.args[1],1), ∞))
131+
pad(c::BlockVec, ax::BlockedOneTo{Int,<:InfStepRange}) = BlockVec(pad(c.args[1], size(c.args[1],1), ∞))
132132

133133
export Vcat, Fill, ql, ql!, ∞, ContinuousSpectrumError, BlockTridiagonal
134134

src/banded/infbanded.jl

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -381,11 +381,11 @@ _BandedMatrix(::PertToeplitzLayout, A::AbstractMatrix) =
381381
@inline sub_materialize(::BandedColumns, V, ::Tuple{InfAxes,InfAxes}) = BandedMatrix(V)
382382
@inline sub_materialize(::BandedColumns, V, ::Tuple{InfAxes,OneTo{Int}}) = BandedMatrix(V)
383383

384-
sub_materialize(_, V, ::Tuple{<:BlockedUnitRange{<:InfRanges}}) = V
385-
sub_materialize(::AbstractBlockLayout, V, ::Tuple{<:BlockedUnitRange{<:InfRanges}}) = V
386-
function sub_materialize(::PaddedLayout, v::AbstractVector{T}, ax::Tuple{<:BlockedUnitRange{<:InfRanges}}) where T
384+
sub_materialize(_, V, ::Tuple{BlockedOneTo{Int,<:InfRanges}}) = V
385+
sub_materialize(::AbstractBlockLayout, V, ::Tuple{BlockedOneTo{Int,<:InfRanges}}) = V
386+
function sub_materialize(::PaddedColumns, v::AbstractVector{T}, ax::Tuple{BlockedOneTo{Int,<:InfRanges}}) where T
387387
dat = paddeddata(v)
388-
PseudoBlockVector(Vcat(sub_materialize(dat), Zeros{T}(∞)), ax)
388+
BlockedVector(Vcat(sub_materialize(dat), Zeros{T}(∞)), ax)
389389
end
390390

391391
##
@@ -446,14 +446,14 @@ _bandedfill_mul(M::MulAdd, ::Tuple{Any,InfAxes}, ::Tuple{InfAxes,Any}) = ApplyAr
446446

447447
mulreduce(M::Mul{<:InfToeplitzLayouts, <:InfToeplitzLayouts}) = ApplyArray(M)
448448
mulreduce(M::Mul{<:InfToeplitzLayouts}) = ApplyArray(M)
449-
mulreduce(M::Mul{<:InfToeplitzLayouts,<:PaddedLayout}) = MulAdd(M)
449+
mulreduce(M::Mul{<:InfToeplitzLayouts,<:PaddedColumns}) = MulAdd(M)
450450
mulreduce(M::Mul{<:Any, <:InfToeplitzLayouts}) = ApplyArray(M)
451451
mulreduce(M::Mul{<:AbstractQLayout, <:InfToeplitzLayouts}) = ApplyArray(M)
452452
mulreduce(M::Mul{<:DiagonalLayout, <:InfToeplitzLayouts}) = Lmul(M)
453453
mulreduce(M::Mul{<:InfToeplitzLayouts, <:DiagonalLayout}) = Rmul(M)
454454

455455

456-
function _bidiag_forwardsub!(M::Ldiv{<:Any,<:PaddedLayout})
456+
function _bidiag_forwardsub!(M::Ldiv{<:Any,<:PaddedColumns})
457457
A, b_in = M.A, M.B
458458
dv = diagonaldata(A)
459459
ev = subdiagonaldata(A)
@@ -536,4 +536,12 @@ Base.typed_hcat(::Type{T}, A::BandedMatrix{<:Any,<:Any,OneToInf{Int}}, B::Abstra
536536
# SymTriPertToeplitz
537537
###
538538

539-
MemoryLayout(::Type{<:SymTriPertToeplitz}) = PertTridiagonalToeplitzLayout()
539+
MemoryLayout(::Type{<:SymTriPertToeplitz}) = PertTridiagonalToeplitzLayout()
540+
541+
542+
####
543+
# Banded, TODO: move to extension in InfiniteArrays.jl
544+
###
545+
546+
sublayout(::ApplyBandedLayout, ::Type{<:Tuple{KR,Integer}}) where {KR<:InfAxes} =
547+
sublayout(PaddedColumns{UnknownLayout}(), Tuple{KR})

src/blockbanded/blockbanded.jl

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ BlockArrays.sortedunion(a::OneToInfCumsum, ::OneToInfCumsum) = a
1515
BlockBandedMatrices.blockbanded_colstop(A, x::InfiniteCardinal{0}) = x
1616
BlockBandedMatrices.blockbanded_rowstop(A, x::InfiniteCardinal{0}) = x
1717

18+
BlockArrays.blocklasts(a::InfRanges) = Fill(length(a),1)
1819

1920

2021
function BlockArrays.sortedunion(a::Vcat{Int,1,<:Tuple{Union{Int,AbstractVector{Int}},<:AbstractRange}},
@@ -24,10 +25,10 @@ function BlockArrays.sortedunion(a::Vcat{Int,1,<:Tuple{Union{Int,AbstractVector{
2425
end
2526

2627
sizes_from_blocks(A::AbstractVector, ::Tuple{OneToInf{Int}}) = (map(length,A),)
27-
length(::BlockedUnitRange{<:InfRanges}) = ℵ₀
28+
length(::BlockedOneTo{Int,<:InfRanges}) = ℵ₀
2829

29-
const OneToInfBlocks = BlockedUnitRange{OneToInfCumsum}
30-
const OneToBlocks = BlockedUnitRange{OneToCumsum}
30+
const OneToInfBlocks = BlockedOneTo{Int,OneToInfCumsum}
31+
const OneToBlocks = BlockedOneTo{Int,OneToCumsum}
3132

3233
axes(a::OneToInfBlocks) = (a,)
3334
axes(a::OneToBlocks) = (a,)
@@ -48,9 +49,9 @@ function copy(bc::Broadcasted{<:BroadcastStyle,<:Any,typeof(*),<:Tuple{AbstractA
4849
convert(AbstractArray{promote_type(T,V),N}, a)
4950
end
5051

51-
_block_interlace_axes(::Int, ax::Tuple{BlockedUnitRange{OneToInf{Int}}}...) = (blockedrange(Fill(length(ax), ∞)),)
52+
_block_interlace_axes(::Int, ax::Tuple{BlockedOneTo{Int,OneToInf{Int}}}...) = (blockedrange(Fill(length(ax), ∞)),)
5253

53-
_block_interlace_axes(nbc::Int, ax::NTuple{2,BlockedUnitRange{OneToInf{Int}}}...) =
54+
_block_interlace_axes(nbc::Int, ax::NTuple{2,BlockedOneTo{Int,OneToInf{Int}}}...) =
5455
(blockedrange(Fill(length(ax) ÷ nbc, ∞)),blockedrange(Fill(mod1(length(ax),nbc), ∞)))
5556

5657

@@ -66,10 +67,10 @@ BroadcastStyle(::Type{<:SubArray{T,N,Arr,<:NTuple{N,BlockSlice{BlockRange{1,Tupl
6667
LazyArrayStyle{N}()
6768

6869
# TODO: generalise following
69-
BroadcastStyle(::Type{<:BlockArray{T,N,<:AbstractArray{<:AbstractArray{T,N},N},<:NTuple{N,BlockedUnitRange{<:InfRanges}}}}) where {T,N} = LazyArrayStyle{N}()
70-
# BroadcastStyle(::Type{<:PseudoBlockArray{T,N,<:AbstractArray{T,N},<:NTuple{N,BlockedUnitRange{<:InfRanges}}}}) where {T,N} = LazyArrayStyle{N}()
71-
BroadcastStyle(::Type{<:BlockArray{T,N,<:AbstractArray{<:AbstractArray{T,N},N},<:NTuple{N,BlockedUnitRange{<:RangeCumsum{Int,<:InfRanges}}}}}) where {T,N} = LazyArrayStyle{N}()
72-
# BroadcastStyle(::Type{<:PseudoBlockArray{T,N,<:AbstractArray{T,N},<:NTuple{N,BlockedUnitRange{<:RangeCumsum{Int,<:InfRanges}}}}}) where {T,N} = LazyArrayStyle{N}()
70+
BroadcastStyle(::Type{<:BlockArray{T,N,<:AbstractArray{<:AbstractArray{T,N},N},<:NTuple{N,BlockedOneTo{Int,<:InfRanges}}}}) where {T,N} = LazyArrayStyle{N}()
71+
# BroadcastStyle(::Type{<:BlockedArray{T,N,<:AbstractArray{T,N},<:NTuple{N,BlockedOneTo{Int,<:InfRanges}}}}) where {T,N} = LazyArrayStyle{N}()
72+
BroadcastStyle(::Type{<:BlockArray{T,N,<:AbstractArray{<:AbstractArray{T,N},N},<:NTuple{N,BlockedOneTo{Int,<:RangeCumsum{Int,<:InfRanges}}}}}) where {T,N} = LazyArrayStyle{N}()
73+
# BroadcastStyle(::Type{<:BlockedArray{T,N,<:AbstractArray{T,N},<:NTuple{N,BlockedOneTo{Int,<:RangeCumsum{Int,<:InfRanges}}}}}) where {T,N} = LazyArrayStyle{N}()
7374

7475

7576
###
@@ -80,7 +81,7 @@ _krontrav_axes(A::OneToInf{Int}, B::OneToInf{Int}) = blockedrange(oneto(length(A
8081

8182

8283
struct InfKronTravBandedBlockBandedLayout <: AbstractLazyBandedBlockBandedLayout end
83-
MemoryLayout(::Type{<:KronTrav{<:Any,2,<:Any,NTuple{2,BlockedUnitRange{OneToInfCumsum}}}}) = InfKronTravBandedBlockBandedLayout()
84+
MemoryLayout(::Type{<:KronTrav{<:Any,2,<:Any,NTuple{2,BlockedOneTo{Int,OneToInfCumsum}}}}) = InfKronTravBandedBlockBandedLayout()
8485

8586
sublayout(::InfKronTravBandedBlockBandedLayout, ::Type{<:NTuple{2,BlockSlice1}}) = BroadcastBandedLayout{typeof(*)}()
8687
sublayout(::InfKronTravBandedBlockBandedLayout, ::Type{<:NTuple{2,BlockSlice{BlockRange{1,Tuple{OneTo{Int}}}}}}) = KronTravBandedBlockBandedLayout()

src/blockbanded/infblocktridiagonal.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
const BlockTriPertToeplitz{T} = BlockMatrix{T,Tridiagonal{Matrix{T},Vcat{Matrix{T},1,Tuple{Vector{Matrix{T}},Fill{Matrix{T},1,Tuple{OneToInf{Int}}}}}},
2-
NTuple{2,BlockedUnitRange{Vcat{Int,1,Tuple{Vector{Int},InfStepRange{Int,Int}}}}}}
2+
NTuple{2,BlockedOneTo{Int,Vcat{Int,1,Tuple{Vector{Int},InfStepRange{Int,Int}}}}}}
33

44
const BlockTridiagonalToeplitzLayout = BlockLayout{TridiagonalToeplitzLayout,DenseColumnMajor}
55

@@ -38,7 +38,7 @@ sizes_from_blocks(A::Bidiagonal, ::NTuple{2,OneToInf{Int}}) = size.(A.dv, 1), si
3838
sizes_from_blocks(A::LazyBandedMatrices.Bidiagonal, ::NTuple{2,OneToInf{Int}}) = size.(A.dv, 1), size.(A.dv,2)
3939

4040
axes_print_matrix_row(_, io, X, A, i, ::AbstractVector{<:PosInfinity}, sep) = nothing
41-
axes_print_matrix_row(::NTuple{2,BlockedUnitRange}, io, X, A, i, ::AbstractVector{<:PosInfinity}, sep) = nothing
41+
axes_print_matrix_row(::NTuple{2,AbstractBlockedUnitRange}, io, X, A, i, ::AbstractVector{<:PosInfinity}, sep) = nothing
4242

4343

4444
function BlockSkylineSizes(A::BlockTriPertToeplitz, (l,u)::NTuple{2,Int})

src/infcholesky.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ end
6969
colsupport(F::AdjOrTrans{<:Any,<:AdaptiveCholeskyFactors}, j) = rowsupport(parent(F), j)
7070
rowsupport(F::AdjOrTrans{<:Any,<:AdaptiveCholeskyFactors}, j) = colsupport(parent(F), j)
7171

72-
function materialize!(M::MatLdivVec{<:TriangularLayout{'L','N',<:AdaptiveLayout},<:PaddedLayout})
72+
function materialize!(M::MatLdivVec{<:TriangularLayout{'L','N',<:AdaptiveLayout},<:AbstractPaddedLayout})
7373
A,B = M.A,M.B
7474
T = eltype(M)
7575
COLGROWTH = 1000 # rate to grow columns

src/infql.jl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ getL(Q::QL, ::NTuple{2,InfiniteCardinal{0}}) = LowerTriangular(Q.factors)
9696
getL(Q::QLHessenberg, ::NTuple{2,InfiniteCardinal{0}}) = LowerTriangular(Q.factors)
9797

9898

99-
function materialize!(M::Lmul{<:QLPackedQLayout{<:BandedColumns},<:PaddedLayout})
99+
function materialize!(M::Lmul{<:QLPackedQLayout{<:BandedColumns},<:AbstractPaddedLayout})
100100
A,B = M.A,M.B
101101
require_one_based_indexing(B)
102102
mA, nA = size(A.factors)
@@ -130,7 +130,7 @@ function materialize!(M::Lmul{<:QLPackedQLayout{<:BandedColumns},<:PaddedLayout}
130130
B
131131
end
132132

133-
function materialize!(M::Lmul{<:AdjQLPackedQLayout{<:BandedColumns},<:PaddedLayout})
133+
function materialize!(M::Lmul{<:AdjQLPackedQLayout{<:BandedColumns},<:AbstractPaddedLayout})
134134
adjA,B = M.A,M.B
135135
require_one_based_indexing(B)
136136
A = parent(adjA)
@@ -174,7 +174,7 @@ function blocktailiterate(c,a,b, d=c, e=a)
174174
d̃,ẽ = QLPackedQ(F.factors[1:n,n+1:2n],F.τ[1:n])*d̃,QLPackedQ(F.factors[1:n,n+1:2n],F.τ[1:n])*# undo last rotation
175175
if (d̃, d; atol=1E-10) && (ẽ, e; atol=1E-10)
176176
X[1:n,1:n] = d̃; X[1:n,n+1:2n] =
177-
return PseudoBlockArray(X,fill(n,2), fill(n,3)), F.τ[n+1:2n]
177+
return BlockedArray(X,fill(n,2), fill(n,3)), F.τ[n+1:2n]
178178
end
179179
d,e = d̃,ẽ
180180
end
@@ -266,7 +266,7 @@ end
266266
ldiv!(F::QLProduct, b::AbstractVector) = ldiv!(F.L, lmul!(F.Q',b))
267267
ldiv!(F::QLProduct, b::LayoutVector) = ldiv!(F.L, lmul!(F.Q',b))
268268

269-
function materialize!(M::MatLdivVec{<:TriangularLayout{'L','N',BandedColumns{PertConstRows}},<:PaddedLayout})
269+
function materialize!(M::MatLdivVec{<:TriangularLayout{'L','N',BandedColumns{PertConstRows}},<:AbstractPaddedLayout})
270270
A,b = M.A,M.B
271271
require_one_based_indexing(A, b)
272272
n = size(A, 2)
@@ -290,7 +290,7 @@ end
290290

291291
ql_layout(layout, ::NTuple{2,OneToInf{Int}}, A, args...; kwds...) = error("Not implemented")
292292

293-
_data_tail(::PaddedLayout, a) = paddeddata(a), zero(eltype(a))
293+
_data_tail(::PaddedColumns, a) = paddeddata(a), zero(eltype(a))
294294
_data_tail(::AbstractFillLayout, a) = Vector{eltype(a)}(), getindex_value(a)
295295
_data_tail(::CachedLayout, a) = cacheddata(a), getindex_value(a.array)
296296
function _data_tail(::ApplyLayout{typeof(vcat)}, a)
@@ -495,9 +495,9 @@ getindex(Q::QLPackedQ{<:Any,<:AdaptiveQLFactors}, I::Int, J::UnitRange{Int}) =
495495
getindex(Q::QLPackedQ{<:Any,<:AdaptiveQLFactors}, I::UnitRange{Int}, J::Int) =
496496
[Q[i,j] for i in I, j in J]
497497

498-
materialize!(M::Lmul{<:QLPackedQLayout{<:LazyLayout},<:PaddedLayout}) = ApplyArray(*,M.A,M.B)
498+
materialize!(M::Lmul{<:QLPackedQLayout{<:LazyLayout},<:AbstractPaddedLayout}) = ApplyArray(*,M.A,M.B)
499499

500-
function materialize!(M::Lmul{<:AdjQLPackedQLayout{<:LazyLayout},<:PaddedLayout})
500+
function materialize!(M::Lmul{<:AdjQLPackedQLayout{<:LazyLayout},<:AbstractPaddedLayout})
501501
adjA,B = M.A,M.B
502502
A = parent(adjA)
503503
mA, nA = size(A.factors)

src/infqr.jl

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ function partialqr!(F::AdaptiveQRData{<:Any,<:BlockSkylineMatrix}, N::Block{1})
7878
zero!(τ)
7979
else
8080
factors = view(F.data.data,Ñ+1:N+l,Ñ+1:N+u);
81-
_blockbanded_qr!(factors, PseudoBlockVector(τ, (axes(factors,2)[Block(1):(N-Ñ)],)), N-Ñ)
81+
_blockbanded_qr!(factors, BlockedVector(τ, (axes(factors,2)[Block(1):(N-Ñ)],)), N-Ñ)
8282
end
8383
F.ncols = n
8484
end
@@ -170,7 +170,7 @@ getindex(Q::QRPackedQ{<:Any,<:AdaptiveQRFactors,<:AdaptiveQRTau}, I::AbstractVec
170170
#########
171171

172172
_view_QRPackedQ(A, kr, jr) = QRPackedQ(view(A.factors.data.data.data,kr,jr), view(A.τ.data.τ,jr))
173-
function materialize!(M::MatLmulVec{<:QRPackedQLayout{<:AdaptiveLayout},<:PaddedLayout})
173+
function materialize!(M::MatLmulVec{<:QRPackedQLayout{<:AdaptiveLayout},<:AbstractPaddedLayout})
174174
A,B = M.A,M.B
175175
sB = size(paddeddata(B),1)
176176
partialqr!(A.factors.data,sB)
@@ -197,7 +197,7 @@ function resizedata_chop!(v::CachedVector, tol)
197197
v
198198
end
199199

200-
function resizedata_chop!(v::PseudoBlockVector, tol)
200+
function resizedata_chop!(v::BlockedVector, tol)
201201
c = paddeddata(v.blocks)
202202
n = length(c)
203203
k_tol = choplength(c, tol)
@@ -212,7 +212,7 @@ end
212212

213213
_norm(x::Number) = abs(x)
214214

215-
function materialize!(M::MatLmulVec{<:AdjQRPackedQLayout{<:AdaptiveLayout},<:PaddedLayout}; tolerance=floatmin(real(eltype(M))))
215+
function materialize!(M::MatLmulVec{<:AdjQRPackedQLayout{<:AdaptiveLayout},<:AbstractPaddedLayout}; tolerance=floatmin(real(eltype(M))))
216216
adjA,B = M.A,M.B
217217
COLGROWTH = 1000 # rate to grow columns
218218

@@ -252,7 +252,7 @@ function materialize!(M::MatLmulVec{<:AdjQRPackedQLayout{<:AdaptiveLayout},<:Pad
252252
resizedata_chop!(B, tolerance)
253253
end
254254

255-
function resizedata!(B::PseudoBlockVector, M::Block{1})
255+
function resizedata!(B::BlockedVector, M::Block{1})
256256
resizedata!(B.blocks, last(axes(B,1)[M]))
257257
B
258258
end
@@ -263,11 +263,11 @@ function _view_QRPackedQ(A, KR::BlockRange, JR::BlockRange)
263263
QRPackedQ(view(A.factors.data.data.data,KR,JR), view(A.τ.data.τ,jr))
264264
end
265265

266-
function materialize!(M::MatLmulVec{<:QRPackedQLayout{<:AdaptiveLayout{<:AbstractBlockBandedLayout}},<:PaddedLayout})
266+
function materialize!(M::MatLmulVec{<:QRPackedQLayout{<:AdaptiveLayout{<:AbstractBlockBandedLayout}},<:AbstractPaddedLayout})
267267
A,B_in = M.A,M.B
268268
sB = length(paddeddata(B_in))
269269
ax1,ax2 = axes(A.factors.data.data)
270-
B = PseudoBlockVector(B_in, (ax2,))
270+
B = BlockedVector(B_in, (ax2,))
271271
SB = findblock(ax2, sB)
272272
partialqr!(A.factors.data,SB)
273273
JR = Block(1):SB
@@ -279,13 +279,13 @@ function materialize!(M::MatLmulVec{<:QRPackedQLayout{<:AdaptiveLayout{<:Abstrac
279279
B
280280
end
281281

282-
function materialize!(M::MatLmulVec{<:AdjQRPackedQLayout{<:AdaptiveLayout{<:AbstractBlockBandedLayout}},<:PaddedLayout}; tolerance=1E-30)
282+
function materialize!(M::MatLmulVec{<:AdjQRPackedQLayout{<:AdaptiveLayout{<:AbstractBlockBandedLayout}},<:AbstractPaddedLayout}; tolerance=1E-30)
283283
adjA,B_in = M.A,M.B
284284
A = parent(adjA)
285285
T = eltype(M)
286286
COLGROWTH = 300 # rate to grow columns
287287
ax1,ax2 = axes(A.factors.data.data)
288-
B = PseudoBlockVector(B_in, (ax1,))
288+
B = BlockedVector(B_in, (ax1,))
289289

290290
SB = findblock(ax1, length(paddeddata(B_in)))
291291
MA, NA = blocksize(A.factors.data.data.array)
@@ -334,7 +334,7 @@ function ldiv!(R::UpperTriangular{<:Any,<:AdaptiveQRFactors}, B::CachedVector{<:
334334
end
335335

336336

337-
function ldiv!(R::UpperTriangular{<:Any,<:AdaptiveQRFactors}, B::PseudoBlockArray)
337+
function ldiv!(R::UpperTriangular{<:Any,<:AdaptiveQRFactors}, B::BlockedArray)
338338
n = B.blocks.datasize[1]
339339
N = findblock(axes(R,1),n)
340340
partialqr!(parent(R).data, N)

0 commit comments

Comments
 (0)