@@ -124,7 +124,7 @@ function Base.show(io::IO, ::MIME"text/plain", p::AbstractParticles{T,N}) where
124124 end
125125end
126126
127- function Base. show (io:: IO , :: MIME"text/plain" , z:: Complex{<:AbstractParticles} )
127+ function Base. show (io:: IO , z:: Complex{<:AbstractParticles} )
128128 r, i = reim (z)
129129 compact = get (io, :compact , false )
130130 print (io, " (" )
@@ -243,9 +243,9 @@ for PT in ParticleSymbols
243243 Helper function for performing uncertainty propagation through complex-valued functions with vector inputs.
244244 Applies `f : ℝⁿ → Cⁿ` to an array of particles. E.g., `LinearAlgebra.eigvals(p::Matrix{<:AbstractParticles}) = ℝⁿ2ℂⁿ_function(eigvals,p)`
245245 """
246- function ℝⁿ2ℂⁿ_function (f:: F , p:: AbstractArray{$PT{T,N}} ) where {F,T,N}
246+ function ℝⁿ2ℂⁿ_function (f:: F , p:: AbstractArray{$PT{T,N}} ; kwargs ... ) where {F,T,N}
247247 individuals = map (1 : length (p[1 ])) do i
248- f (getindex .(p,i))
248+ f (getindex .(p,i); kwargs ... )
249249 end
250250 PRT = $ PT{T,N}
251251 RT = eltype (eltype (individuals))
@@ -558,7 +558,7 @@ LinearAlgebra.norm(x::AbstractParticles, args...) = abs(x)
558558
559559
560560Base. log (p:: Matrix{<:AbstractParticles} ) = ℝⁿ2ℂⁿ_function (log,p) # Matrix more specific than StridedMatrix used in Base.log
561- LinearAlgebra. eigvals (p:: Matrix{<:AbstractParticles} ) = ℝⁿ2ℂⁿ_function (eigvals,p)
561+ # LinearAlgebra.eigvals(p::Matrix{<:AbstractParticles}; kwargs... ) = ℝⁿ2ℂⁿ_function(eigvals,p; kwargs...) # Replaced with implementation below
562562Base. exp (p:: AbstractMatrix{<:AbstractParticles} ) = ℝⁿ2ℝⁿ_function (exp, p)
563563LinearAlgebra. lyap (p1:: Matrix{<:AbstractParticles} , p2:: Matrix{<:AbstractParticles} ) = ℝⁿ2ℝⁿ_function (lyap, p1, p2)
564564
0 commit comments