%% 
%%  A DANTE-Edition example
%% 
%% 
%%  Copyright (C) 2011 Herbert Voss
%% 
%%  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.
%% 
%% 
%% ==== 
% Show page(s) 1
%% 
\documentclass[]{article}
\pagestyle{empty}
\setlength\textwidth{201.70511pt}
\setlength\parindent{0pt}

\usepackage{pst-plot,pst-func}
\newcommand*\plot[3][linecolor=black]{%
  \pstVerb{/lambda #2 def }
  \psplot[#1]{0}{#3}{ x Func }%
}
\pstVerb{/Func { % x has to be on top of the stack
  lambda mul neg Euler exch exp lambda mul } def }

\begin{document}
\psset{yunit=3cm,xunit=2cm}
\begin{pspicture}(4,2.5)
  \psaxes{->}(4,2.5)
  \plot[linewidth=1.5pt,linecolor=red]{2}{3.8}
  \psline[linestyle=dashed](!0 .5 Func)(!.5 dup Func)(0.5,0)
  \rput[lb](! .6 .5 Func){\psPrintValue{0.5 Func}}
  \rput(2,2){$f(x)=\lambda\cdot e^{-\lambda x}$}
\end{pspicture}
\end{document}
