%% %% The LaTeX Graphics Companion, 2ed (first printing May 2007) %% %% Example 6-7-10 on page 423. %% %% Copyright (C) 2007 Michel Goossens, Frank Mittelbach, Denis Roegel, Sebastian Rahtz, Herbert Vo\ss %% %% It may be distributed and/or modified under the conditions %% of the LaTeX Project Public License, either version 1.3 %% of this license or (at your option) any later version. %% %% See http://www.latex-project.org/lppl.txt for details. %% \documentclass{ttctexa} \pagestyle{empty} \setcounter{page}{6} \setlength\textwidth{207.83385pt} \StartShownPreambleCommands \usepackage{pstricks-add} \StopShownPreambleCommands \begin{document} \psset{unit=1.25cm} \begin{pspicture}[plotpoints=200](-0.5,-3)(10,2.5) \psStep[algebraic,fillstyle=solid,fillcolor=yellow] (0.001,9.5){40}{2*sqrt(x)*cos(ln(x))*sin(x)} \psStep[algebraic,StepType=Riemann,fillstyle=solid,fillcolor=blue] (0.001,9.5){40}{2*sqrt(x)*cos(ln(x))*sin(x)} \psaxes{->}(0,0)(0,-2.75)(10,2.5) \psplot[algebraic,linecolor=white,labelFontSize=\footnotesize] {0.001}{9.75}{2*sqrt(x)*cos(ln(x))*sin(x)} \uput[90](6,1.2){$f(x)=2\cdot\sqrt{x}\cdot\cos{(\ln{x})}\cdot\sin{x}$} \end{pspicture} \end{document}