Changes between Version 1 and Version 2 of Ticket #9706, comment 72
- Timestamp:
- 12/05/13 08:50:43 (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #9706, comment 72
v1 v2 1 1 I think that `chebyshev_T(1/2, 2)` should raise a `ValueError` (or can we make sense of this?). So, in your code there should really be 3 cases: integer, symbolic and "something else" which is always an error. 2 3 Also: the code block you wrote above is a good example of something would could fit in the generic `SymbolicPolynomial` (or `OrthogonalPolynomial` if you like) class. So I wouldn't use `super(OrthogonalPolynomial,self)` but `super(BuiltinFunction, self)`.4 2 5 3 So, I would do something like … … 7 5 def __call__(self,n,x): 8 6 if is_Expression(n): 9 return super( BuiltinFunction, self).__call__(n,x)7 return super(OrthogonalPolynomial, self).__call__(n,x) 10 8 # We consider the polynomial really as a polynomial, 11 9 # not a symbolic expression.