-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add StaticArrays extension * Bump patch version * Add promote_op for matrix-matrix product * Update runtests.jl * Add Base.float dispatches for TaylorSeries types and variables
- Loading branch information
Showing
9 changed files
with
87 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module TaylorSeriesSAExt | ||
|
||
using TaylorSeries | ||
|
||
import Base.promote_op | ||
import LinearAlgebra: matprod | ||
|
||
isdefined(Base, :get_extension) ? (using StaticArrays) : (using ..StaticArrays) | ||
|
||
promote_op(::typeof(adjoint), ::Type{T}) where {T<:AbstractSeries} = T | ||
promote_op(::typeof(matprod), ::Type{T}, ::Type{U}) where {T <: AbstractSeries, U <: AbstractFloat} = T | ||
promote_op(::typeof(matprod), ::Type{T}, ::Type{T}) where {T <: AbstractSeries} = T | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# This file is part of TaylorSeries.jl, MIT licensed | ||
# | ||
|
||
using TaylorSeries, StaticArrays | ||
|
||
using Test | ||
# eeuler = Base.MathConstants.e | ||
|
||
@testset "Tests TaylorSeries operations over StaticArrays types" begin | ||
q = set_variables("q", order=2, numvars=2) | ||
m = @SMatrix fill(Taylor1(rand(2).*q), 3, 3) | ||
mt = m' | ||
@test m isa SMatrix{3, 3, Taylor1{TaylorN{Float64}}, 9} | ||
@test mt isa SMatrix{3, 3, Taylor1{TaylorN{Float64}}, 9} | ||
v = @SVector [-1.1, 3.4, 7.62345e-1] | ||
mtv = mt * v | ||
@test mtv isa SVector{3, Taylor1{TaylorN{Float64}}} | ||
mmt = m * mt | ||
@test mmt isa SMatrix{3, 3, Taylor1{TaylorN{Float64}}, 9} | ||
end |
a79b022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JuliaRegistrator register
a79b022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Registration pull request created: JuliaRegistries/General/103938
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via: