[pstricks] PSTricks Digest, Vol 154, Issue 15
Germain Boyer
germain.boyer at ac-toulouse.fr
Thu Nov 26 22:03:08 CET 2015
Bonjour,
Thanks Herbert for your answer.
I modified just a little your answer to have the same result as my initial
pspicture.
Here is my code :
\documentclass[a4paper,11pt]{article}
\usepackage{fourier}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{pst-func,pst-plot,pstricks-add}
\usepackage{geometry}
\geometry{nohead,nofoot,left=3.5cm,right=3.5cm,top=1cm,bottom=1cm}
\usepackage[french]{babel}
\usepackage[np]{numprint}
%
\begin{document}
%
\psset{xunit=0.003cm,yunit=2cm,arrowinset=0,arrowscale=1.25,algebraic=true,tickwidth=0.75pt}
\begin{pspicture}(-500,-1)(3000,3.5)%%%%%% y multiplied by 1000
\psset{gridcolor=gray , gridwidth=0.4pt , gridlabels=0pt , subgriddiv=1}
\psgrid[xunit=500\psxunit,yunit=0.5\psyunit](0,0)(6,7)
\footnotesize
\psaxes[comma,Ox=1500,Dx=500,Dy=1,ylabelFactor=\cdot10^{-3},labels=x,linewidth=1pt]{->}(0,0)(0,0)(3000,3.5)
\multido{\ry=0+0.5 , \n=0+0.0005}{7}{\psyTick(\ry){\np{\n}}}
\normalsize
\psaxes[unit=1cm,linewidth=1pt](0,0)(-2mm,-2mm)(0,0)
\def\m{3000}% moyenne
\def\s{150}% écart type
\newcommand*{\h}{1/(\s*sqrt(2*PI))*EXP((-0.5*(((x+1500)-\m)/\s)^2))}
\psplot[algebraic,plotpoints=5000,linewidth=0.5pt,linecolor=red]{0}{3000}{\h*1000}
% courbe de h sur [1500 ; 4500]
\def\m{3000}% moyenne
\def\s{300}% écart type
\psplot[algebraic=true,plotpoints=5000,linewidth=0.5pt,linecolor=red]{0}{3000}{\h*1000}
% courbe de h sur [1500 ; 4500]
% \psGauss[sigma=150,mue=3000,linecolor=green,yunit=1000]{0}{4000}
\uput[-90](3000,0){$x$}
\uput[180](0,3.5){$y$}
\end{pspicture}
%
\end{document}
Thanks for your answer.
Germain
More information about the PSTricks
mailing list