Department of Mathematics

Math 583: Mathematical Hacking

ICE 1

Create a Python function that evaluates $$s(x) = \begin{cases} 0 & x=0,\\ x\sin\left(\frac1x\right) & \text{otherwise}.\\ \end{cases} $$

Props to those who can do this in one line. Mail the completed .py file to the instructor .

Welcome to Math 583, Hacking Mathematics.





Department of Mathematics, PO Box 643113, Neill Hall 103, Washington State University, Pullman WA 99164-3113, 509-335-3926, Contact Us
Copyright © 2009-15 Kevin Cooper