Hello, I want to create a polynomial type, parametrized by its coefficients, able to perform polynomial additions and such. but I would also like to use it like a function call, since a polynomial should be just like a function Something of the following would be nice:
p = Poly([1,2,3]) # creating a polynomial p(x) = 1 + 2x + 3x^2 q = Poly([1,2]) # creating a polynomial 1 + 2x r = p + q # using dynamic dispatch, creating the polynomial 2 + 4x + 3x^2 r(1) # this should give 9, by evaluating polynomial r at x = 1 Is there something in Julia that would allow me to create what I have in mind? thanks!!
