From 73ebb102ec1d246f9437c85732954a99ec68e051 Mon Sep 17 00:00:00 2001 From: MikaelSlevinsky Date: Thu, 12 Dec 2024 14:35:52 -0600 Subject: [PATCH] add O(bn) GramMatrix constructor from moments --- Project.toml | 2 +- src/GramMatrix.jl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Project.toml b/Project.toml index be1349a..a7e938a 100644 --- a/Project.toml +++ b/Project.toml @@ -1,6 +1,6 @@ name = "FastTransforms" uuid = "057dd010-8810-581a-b7be-e3fc3b93f78c" -version = "0.16.6" +version = "0.16.7" [deps] AbstractFFTs = "621f4979-c628-5d54-868e-fcf4e3e8185c" diff --git a/src/GramMatrix.jl b/src/GramMatrix.jl index e7e8a70..8bf6dc4 100644 --- a/src/GramMatrix.jl +++ b/src/GramMatrix.jl @@ -64,7 +64,7 @@ function GramMatrix(μ::AbstractVector{T}, X::XT, p0::T) where {T, XT <: Abstrac n = (N+1)÷2 @assert N == size(X, 1) == size(X, 2) @assert bandwidths(X) == (1, 1) - W = Matrix{T}(undef, N, N) + W = LowerTriangular(Matrix{T}(undef, N, N)) if n > 0 @inbounds for m in 1:N W[m, 1] = p0*μ[m]