summaryrefslogtreecommitdiff
path: root/Master/texmf/doc/asymptote/examples/xsin1x.asy
blob: f03714b79df849e85a37bb0d90208bcaa1b1ad63 (plain)
1
2
3
4
5
6
7
8
9
10
import graph;
size(300,0);

real f(real x) {return (x != 0.0) ? x * sin(1.0 / x) : 0.0;}
pair F(real x) {return (x,f(x));}

xaxis("$x$",red);
yaxis(red);
draw(graph(f,-1.2/pi,1.2/pi,1000));
label("$x\sin\frac{1}{x}$",F(1.1/pi),NW);