Attached is the first rc of the chebyshev module. The module documentation is not yet complete and no doubt the rest of the documentation needs to be reviewed. The tests cover basic functionality at this point but need to be extended to cover the Chebyshev object. Nevertheless, the module should be usable. Note that the most convenient way to do the least squared fits is with the static method Chebyshev.fit, which will return a Chebyshev object that contains both the resulting Chebyshev series and its domain. Some naming questions remain. ISTM that "lstsq" or "leastsq" might be a better name than fit. Likewise, I have kept the poly1d names "deriv" and "integ", but "der" and "int" might be more appropriate. Operators behave as expected for +, -, and * but there is no truedivision unless both operands can be interpreted as scalars. When division hasn't been imported from __future__, the / and // operators are both floordivision and % returns the remainder. Divmod behaves as expected. Any feedback is welcome. Chuck
On Sat, Oct 3, 2009 at 7:12 PM, Charles R Harris
Attached is the first rc of the chebyshev module. The module documentation is not yet complete and no doubt the rest of the documentation needs to be reviewed. The tests cover basic functionality at this point but need to be extended to cover the Chebyshev object. Nevertheless, the module should be usable.
Note that the most convenient way to do the least squared fits is with the static method Chebyshev.fit, which will return a Chebyshev object that contains both the resulting Chebyshev series and its domain.
Some naming questions remain. ISTM that "lstsq" or "leastsq" might be a better name than fit. Likewise, I have kept the poly1d names "deriv" and "integ", but "der" and "int" might be more appropriate.
Operators behave as expected for +, -, and * but there is no truedivision unless both operands can be interpreted as scalars. When division hasn't been imported from __future__, the / and // operators are both floordivision and % returns the remainder. Divmod behaves as expected.
Any feedback is welcome.
And an updated test to reflect changes in treatment of leading zeros. Chuck
participants (1)
-
Charles R Harris