\documentclass[convert=true,convert={convertexe={convert},density=1200,outext=.png}]{standalone}

\input{figsDefs.tex}

\begin{document}

\shorthandoff{;}	% si babel
	
\begin{tikzpicture}[
	declare function={
		R = 8.314;
		% \theT en 100 K
		% \v en 0.001 m3, échelle *3: V=\v/3
		% pression en bar
%		p(\v) = R*\theT/(\v/3) ;
%		p(\v) = R*\theT/(\v/3)/10 ;
		% \v en 0.0001 m3, échelle *5: V=\v/5
		p(\v) = R*\theT/(\v/20)/10 ;
		a = 3.64;
		b = 0.0429; 		
%		pW(\v) = R*\theT/((\v-b)/3) -a/\v^2; 		
%		pW(\v) = (R*\theT/(\v/3-b) -a/(\v/3)^2)/10; 		
		pW(\v) = (R*\theT/(\v/20-b) -a/(\v/20)^2)/10; 		
	},
	xscale=1
	]
	
%	\newcommand{\pnt}[3][black]{%
%		\begin{scope}[shift={#2}];
%			\fill[color=#1,shift only] (0,0) circle(#3);
%	\end{scope}}
%
%	\newcommand{\vTick}[4][black]{%
%	\begin{scope}[shift={#2}];
%		\draw[#1,shift only] (0,0) +(0,#3) -- +(0,-#3) node[below] {#4};
%	\end{scope}}
%
%	\newcommand{\hTick}[4][black]{%
%	\begin{scope}[shift={#2}];
%		\draw[#1,shift only] (0,0) +(#3,0) -- +(-#3,0) node[left] {#4};
%	\end{scope}}

	
	\draw[->] (0,0) -- (11,0) node[right] {$V[10^{-4}\text{m}^3]$};
	\draw[->] (0,0) -- +(0,11) node[above] {$p [10^5\text{Pa}]$};
	\foreach \val in {0,...,5} {
		\draw ({\val*2},0) +(0,.1) -- +(0,-.1) node[below] {\val};
	}
	\foreach \val in {0,10,...,100} {
		\draw (0,{\val/10}) +(.1,0) -- +(-.1,0) node[left] {{\val}};
	}

%% gaz parfait
%	\pgfmathsetmacro{\theT}{3.25}
%	\draw[smooth, domain={5}:{10}, variable=\v, red, samples=100] plot({\v},{p(\v)}) node[right] {325};
%%	\draw[smooth, domain={2}:{10}, variable=\v, red, samples=100] plot({\v},{pW(\v)}) node[right] {325};
%
%	\pgfmathsetmacro{\theT}{3}
%	\draw[smooth, domain={4.6}:{10}, variable=\v, magenta, samples=100] plot({\v},{p(\v)}) node[right] {300};
%%	\draw[smooth, domain={1.57}:{10}, variable=\v, magenta, samples=100] plot({\v},{pW(\v)}) node[right] {300};
%	
%	\pgfmathsetmacro{\theT}{2.75}
%	\draw[smooth, domain={4.6}:{10}, variable=\v, blue, samples=100] plot({\v},{p(\v)}) node[right] {275};
%%	\draw[smooth, domain={1.4}:{10}, variable=\v, blue, samples=100] plot({\v},{pW(\v)}) node[right] {275};
	
% gaz vdW
	\pgfmathsetmacro{\theT}{3.25}
%	\draw[smooth, domain={5}:{10}, variable=\v, red, samples=100] plot({\v},{p(\v)}) node[right] {325};
	\draw[smooth, domain={2}:{10}, variable=\v, red, samples=100] plot({\v},{pW(\v)}) node[right] {325};
	
	\pgfmathsetmacro{\theT}{3}
%	\draw[smooth, domain={4.6}:{10}, variable=\v, magenta, samples=100] plot({\v},{p(\v)}) node[right] {300};
	\draw[smooth, domain={1.57}:{10}, variable=\v, magenta, samples=100] plot({\v},{pW(\v)}) node[right] {300};
	
	\pgfmathsetmacro{\theT}{2.75}
%	\draw[smooth, domain={4.6}:{10}, variable=\v, blue, samples=100] plot({\v},{p(\v)}) node[right] {275};
	\draw[smooth, domain={1.4}:{10}, variable=\v, blue, samples=100] plot({\v},{pW(\v)}) node[right] {275};

	 
	
\end{tikzpicture}

\end{document}