Skip to content
This repository was archived by the owner on Jul 19, 2023. It is now read-only.

Commit 5b1567c

Browse files
fix some depwarns
1 parent 3a5d7e2 commit 5b1567c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

src/DiffEqOperators.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@ module DiffEqOperators
44

55
import Base: +, -, *, /, \, size, getindex, setindex!, Matrix, convert
66
using DiffEqBase, StaticArrays, LinearAlgebra
7-
import LinearAlgebra: mul!, ldiv!, lmul!, rmul!, axpy!, opnorm, factorize
7+
import LinearAlgebra: mul!, ldiv!, lmul!, rmul!, axpy!, opnorm, factorize, I
88
import DiffEqBase: AbstractDiffEqLinearOperator, update_coefficients!, is_constant
9+
using SparseArrays
910

1011
abstract type AbstractDerivativeOperator{T} <: AbstractDiffEqLinearOperator{T} end
1112
abstract type AbstractDiffEqCompositeOperator{T} <: AbstractDiffEqLinearOperator{T} end

src/derivative_operators/abstract_operator_functions.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ end
192192
return the inner stencil of the matrix transformation. The user will have to manually
193193
incorporate the BCs at the ends.
194194
=#
195-
function Base.sparse(A::AbstractDerivativeOperator{T}) where T
195+
function SparseArrays.sparse(A::AbstractDerivativeOperator{T}) where T
196196
N = A.dimension
197197
mat = spzeros(T, N, N)
198198
v = zeros(T, N)
@@ -214,7 +214,7 @@ end
214214
#=
215215
Fallback methods that use the full representation of the operator
216216
=#
217-
Base.expm(A::AbstractDerivativeOperator{T}) where T = exp(full(A))
217+
Base.exp(A::AbstractDerivativeOperator{T}) where T = exp(full(A))
218218
Base.:\(A::AbstractVecOrMat, B::AbstractDerivativeOperator) = A \ full(B)
219219
Base.:\(A::AbstractDerivativeOperator, B::AbstractVecOrMat) = full(A) \ B
220220
Base.:/(A::AbstractVecOrMat, B::AbstractDerivativeOperator) = A / full(B)

0 commit comments

Comments
 (0)