Skip to content

Type Stability for other StaticVectors while evaluating PolynomialSystem. #46

Description

@manuelbb-upb

Hi,
thanks for the great package!

I noticed, that evaluating a PolynomialSystem at a SVector returns an SVector, but the same does not hold true for SizedVector or MVector.

I currently define

for V in [:SizedVector, :MVector ]
    @eval Base.@propagate_inbounds StaticPolynomials.evaluate( F :: PolynomialSystem, x :: $V ) = $V( StaticPolynomials._evaluate( F, x ) )
    @eval Base.@propagate_inbounds StaticPolynomials.evaluate( F :: PolynomialSystem, x :: $V , p) = $V( StaticPolynomials._evaluate( F, x , p) )
end

in my package, but I think, it would be great to have these definitions in polynomial_system.jl

I guess the other subtypes (FieldVector and SUnitRange) can be neglected.

Should I open a pull request?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions