\documentclass[10pt,a4paper]{report}
\usepackage[height=250mm,width=183mm]{geometry}
\usepackage{preambule}
\usepackage[upright]{fourier}
\graphicspath{{/home/moi/Figures/}}
%\entete{}{}{}%g,d,b


\lstset{numbers=none,language=XCAS,%
keywordstyle =\color{0.4white}\bfseries\small\sffamily,basicstyle=\small\sffamily,
    backgroundcolor=\color{0.9white}}




\begin{document}
\setlength{\parindent}{0pt}
\thispagestyle{empty}

\Enc{Aire d'un triangle}{0.9white}{1} % titre,couleur,taille h


Voici une activité XCAS mise  au point par Odile \textsc{Durand} lors du stage qui  a eu lieu à rezé
le 23 mai 2007. 

\subsection*{Énoncé (Math'x Didier page 70)}

OAB est un triangle isocèle en O avec $OA = 6$ cm, $OB = 6$ cm.
On place M sur [OA] et on note $x = OM$.
On place N sur [OB] tel que $BN = OM$.
Quand le point M varie sur [OA], le triangle OMN varie. 
On souhaite étudier l'aire du triangle OMN en fonction de $x$.

\subsection*{Étape 1}

On ouvre une fenêtre de géométrie (Alt+g) 

\begin{lstlisting}
  O:=point(0,0)
  A:=point(6,0)
  B:=point(0,-6)
  segment(A,B)
  a:=element(0..6)
  M:=point(a,0)
  N:=point(0,-6+a)
  segment(M,N)
  f:=x->aire(triangle(point(0),point(0,-6+x),point(x,0)))
  P:=point(a,f(a))
  coordonnees(P)
\end{lstlisting}


On modifie a avec le curseur et on observe le déplacement de M sur [OA] et le déplacement de P. 

On conjecture alors le maximum de $f$. 

\subsection*{Étape 2}

On fait apparaître la courbe de $f$

\begin{lstlisting}
  plot(f(x),x=0..6,couleur=vert)
\end{lstlisting}


\subsection*{Étape 3}

On fait apparaître la formule de l'aire

\begin{lstlisting}
  f(x)
\end{lstlisting}


\pagebreak

\subsection*{La figure}




%file #g2151772696
% Generated by xcas
\noindent
\begin{pspicture}(-1.3333,-6.4615)(10.6667,5.5385)
\psset{unit=1.3333cm}
\psset{xunit=1.3333cm}
\psset{yunit=0.9231cm}
\psset{linewidth=.5pt}
\psset{arrowsize=2pt 4}
\psset{linecolor=black}
\psline[linestyle=dashed]{->}(-1.0000,0.0000)(8.0000,0.0000)
\psline[linestyle=dashed]{->}(0.0000,-7.0000)(0.0000,6.0000)
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](0.0000,0.0000)
\uput{0.0750}[45.0000](0.0000,0.0000){\color{red} O}
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](6.0000,0.0000)
\uput{0.0750}[45.0000](6.0000,0.0000){\color{red} A}
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](0.0000,-6.0000)
\uput{0.0750}[45.0000](0.0000,-6.0000){\color{red} B}
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psline(6.0000,0.0000)(0.0000,-6.0000)
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](1.8600,0.0000)
\uput{0.0750}[45.0000](1.8600,0.0000){\color{red} M}
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](0.0000,-4.1400)
\uput{0.0750}[45.0000](0.0000,-4.1400){\color{red} N}
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psline(1.8600,0.0000)(0.0000,-4.1400)
\psset{linecolor=red}
\psset{linewidth=0.0000pt}
\psdots[dotstyle=*](1.8600,3.8502)
\uput{0.0750}[45.0000](1.8600,3.8502){\color{red} P}
\psset{linecolor=green}
\psset{linewidth=0.0000pt}
\psline[fillcolor=green](     0.000000,     0.000000)(     0.015000,     0.044888)(     0.030000,     0.089550)(     0.045000,     0.133988)(     0.060000,     0.178200)(     0.075000,     0.222187)(     0.090000,     0.265950)(     0.105000,     0.309487)(     0.120000,     0.352800)(     0.135000,     0.395888)(     0.150000,     0.438750)(     0.165000,     0.481388)(     0.180000,     0.523800)(     0.195000,     0.565988)(     0.210000,     0.607950)(     0.225000,     0.649688)(     0.240000,     0.691200)(     0.255000,     0.732488)(     0.270000,     0.773550)(     0.285000,     0.814388)(     0.300000,     0.855000)(     0.315000,     0.895388)(     0.330000,     0.935550)(     0.345000,     0.975488)(     0.360000,     1.015200)(     0.375000,     1.054688)(     0.390000,     1.093950)(     0.405000,     1.132988)(     0.420000,     1.171800)(     0.435000,     1.210388)(     0.450000,     1.248750)(     0.465000,     1.286888)(     0.480000,     1.324800)(     0.495000,     1.362488)(     0.510000,     1.399950)(     0.525000,     1.437188)(     0.540000,     1.474200)(     0.555000,     1.510988)(     0.570000,     1.547550)(     0.585000,     1.583888)(     0.600000,     1.620000)(     0.615000,     1.655888)(     0.630000,     1.691550)(     0.645000,     1.726988)(     0.660000,     1.762200)(     0.675000,     1.797188)(     0.690000,     1.831950)(     0.705000,     1.866488)(     0.720000,     1.900800)(     0.735000,     1.934888)(     0.750000,     1.968750)(     0.765000,     2.002388)(     0.780000,     2.035800)(     0.795000,     2.068988)(     0.810000,     2.101950)(     0.825000,     2.134688)(     0.840000,     2.167200)(     0.855000,     2.199488)(     0.870000,     2.231550)(     0.885000,     2.263388)(     0.900000,     2.295000)(     0.915000,     2.326388)(     0.930000,     2.357550)(     0.945000,     2.388488)(     0.960000,     2.419200)(     0.975000,     2.449688)(     0.990000,     2.479950)(     1.005000,     2.509988)(     1.020000,     2.539800)(     1.035000,     2.569388)(     1.050000,     2.598750)(     1.065000,     2.627888)(     1.080000,     2.656800)(     1.095000,     2.685488)(     1.110000,     2.713950)(     1.125000,     2.742188)(     1.140000,     2.770200)(     1.155000,     2.797988)(     1.170000,     2.825550)(     1.185000,     2.852887)(     1.200000,     2.880000)(     1.215000,     2.906887)(     1.230000,     2.933550)(     1.245000,     2.959987)(     1.260000,     2.986200)(     1.275000,     3.012187)(     1.290000,     3.037950)(     1.305000,     3.063487)(     1.320000,     3.088800)(     1.335000,     3.113887)(     1.350000,     3.138750)(     1.365000,     3.163387)(     1.380000,     3.187800)(     1.395000,     3.211987)(     1.410000,     3.235950)(     1.425000,     3.259687)(     1.440000,     3.283200)(     1.455000,     3.306487)(     1.470000,     3.329550)(     1.485000,     3.352387)(     1.500000,     3.375000)(     1.515000,     3.397387)(     1.530000,     3.419550)(     1.545000,     3.441487)(     1.560000,     3.463200)(     1.575000,     3.484687)(     1.590000,     3.505950)(     1.605000,     3.526987)(     1.620000,     3.547800)(     1.635000,     3.568387)(     1.650000,     3.588750)(     1.665000,     3.608887)(     1.680000,     3.628800)(     1.695000,     3.648487)(     1.710000,     3.667950)(     1.725000,     3.687187)(     1.740000,     3.706200)(     1.755000,     3.724987)(     1.770000,     3.743550)(     1.785000,     3.761887)(     1.800000,     3.780000)(     1.815000,     3.797887)(     1.830000,     3.815550)(     1.845000,     3.832987)(     1.860000,     3.850200)(     1.875000,     3.867187)(     1.890000,     3.883950)(     1.905000,     3.900487)(     1.920000,     3.916800)(     1.935000,     3.932887)(     1.950000,     3.948750)(     1.965000,     3.964387)(     1.980000,     3.979800)(     1.995000,     3.994987)(     2.010000,     4.009950)(     2.025000,     4.024687)(     2.040000,     4.039200)(     2.055000,     4.053487)(     2.070000,     4.067550)(     2.085000,     4.081387)(     2.100000,     4.095000)(     2.115000,     4.108387)(     2.130000,     4.121550)(     2.145000,     4.134487)(     2.160000,     4.147200)(     2.175000,     4.159687)(     2.190000,     4.171950)(     2.205000,     4.183987)(     2.220000,     4.195800)(     2.235000,     4.207387)(     2.250000,     4.218750)(     2.265000,     4.229887)(     2.280000,     4.240800)(     2.295000,     4.251487)(     2.310000,     4.261950)(     2.325000,     4.272187)(     2.340000,     4.282200)(     2.355000,     4.291987)(     2.370000,     4.301550)(     2.385000,     4.310887)(     2.400000,     4.320000)(     2.415000,     4.328887)(     2.430000,     4.337550)(     2.445000,     4.345987)(     2.460000,     4.354200)(     2.475000,     4.362187)(     2.490000,     4.369950)(     2.505000,     4.377487)(     2.520000,     4.384800)(     2.535000,     4.391887)(     2.550000,     4.398750)(     2.565000,     4.405387)(     2.580000,     4.411800)(     2.595000,     4.417987)(     2.610000,     4.423950)(     2.625000,     4.429688)(     2.640000,     4.435200)(     2.655000,     4.440487)(     2.670000,     4.445550)(     2.685000,     4.450387)(     2.700000,     4.455000)(     2.715000,     4.459388)(     2.730000,     4.463550)(     2.745000,     4.467487)(     2.760000,     4.471200)(     2.775000,     4.474687)(     2.790000,     4.477950)(     2.805000,     4.480988)(     2.820000,     4.483800)(     2.835000,     4.486388)(     2.850000,     4.488750)(     2.865000,     4.490888)(     2.880000,     4.492800)(     2.895000,     4.494487)(     2.910000,     4.495950)(     2.925000,     4.497187)(     2.940000,     4.498200)(     2.955000,     4.498988)(     2.970000,     4.499550)(     2.985000,     4.499887)(     3.000000,     4.500000)(     3.015000,     4.499887)(     3.030000,     4.499550)(     3.045000,     4.498988)(     3.060000,     4.498200)(     3.075000,     4.497187)(     3.090000,     4.495950)(     3.105000,     4.494487)(     3.120000,     4.492800)(     3.135000,     4.490887)(     3.150000,     4.488750)(     3.165000,     4.486387)(     3.180000,     4.483800)(     3.195000,     4.480987)(     3.210000,     4.477950)(     3.225000,     4.474687)(     3.240000,     4.471200)(     3.255000,     4.467487)(     3.270000,     4.463550)(     3.285000,     4.459387)(     3.300000,     4.455000)(     3.315000,     4.450387)(     3.330000,     4.445550)(     3.345000,     4.440487)(     3.360000,     4.435200)(     3.375000,     4.429687)(     3.390000,     4.423950)(     3.405000,     4.417987)(     3.420000,     4.411800)(     3.435000,     4.405387)(     3.450000,     4.398750)(     3.465000,     4.391887)(     3.480000,     4.384800)(     3.495000,     4.377487)(     3.510000,     4.369950)(     3.525000,     4.362187)(     3.540000,     4.354200)(     3.555000,     4.345987)(     3.570000,     4.337550)(     3.585000,     4.328887)(     3.600000,     4.320000)(     3.615000,     4.310887)(     3.630000,     4.301550)(     3.645000,     4.291987)(     3.660000,     4.282200)(     3.675000,     4.272187)(     3.690000,     4.261950)(     3.705000,     4.251487)(     3.720000,     4.240800)(     3.735000,     4.229887)(     3.750000,     4.218750)(     3.765000,     4.207387)(     3.780000,     4.195800)(     3.795000,     4.183987)(     3.810000,     4.171950)(     3.825000,     4.159687)(     3.840000,     4.147200)(     3.855000,     4.134487)(     3.870000,     4.121550)(     3.885000,     4.108387)(     3.900000,     4.095000)(     3.915000,     4.081387)(     3.930000,     4.067550)(     3.945000,     4.053487)(     3.960000,     4.039200)(     3.975000,     4.024687)(     3.990000,     4.009950)(     4.005000,     3.994987)(     4.020000,     3.979800)(     4.035000,     3.964387)(     4.050000,     3.948750)(     4.065000,     3.932887)(     4.080000,     3.916800)(     4.095000,     3.900487)(     4.110000,     3.883950)(     4.125000,     3.867187)(     4.140000,     3.850200)(     4.155000,     3.832987)(     4.170000,     3.815550)(     4.185000,     3.797887)(     4.200000,     3.780000)(     4.215000,     3.761887)(     4.230000,     3.743550)(     4.245000,     3.724987)(     4.260000,     3.706200)(     4.275000,     3.687187)(     4.290000,     3.667950)(     4.305000,     3.648487)(     4.320000,     3.628800)(     4.335000,     3.608887)(     4.350000,     3.588750)(     4.365000,     3.568387)(     4.380000,     3.547800)(     4.395000,     3.526987)(     4.410000,     3.505950)(     4.425000,     3.484687)(     4.440000,     3.463200)(     4.455000,     3.441487)(     4.470000,     3.419550)(     4.485000,     3.397387)(     4.500000,     3.375000)(     4.515000,     3.352388)(     4.530000,     3.329550)(     4.545000,     3.306488)(     4.560000,     3.283200)(     4.575000,     3.259688)(     4.590000,     3.235950)(     4.605000,     3.211988)(     4.620000,     3.187800)(     4.635000,     3.163388)(     4.650000,     3.138750)(     4.665000,     3.113888)(     4.680000,     3.088800)(     4.695000,     3.063488)(     4.710000,     3.037950)(     4.725000,     3.012188)(     4.740000,     2.986200)(     4.755000,     2.959988)(     4.770000,     2.933550)(     4.785000,     2.906888)(     4.800000,     2.880000)(     4.815000,     2.852888)(     4.830000,     2.825550)(     4.845000,     2.797988)(     4.860000,     2.770200)(     4.875000,     2.742188)(     4.890000,     2.713950)(     4.905000,     2.685488)(     4.920000,     2.656800)(     4.935000,     2.627888)(     4.950000,     2.598750)(     4.965000,     2.569388)(     4.980000,     2.539800)(     4.995000,     2.509988)(     5.010000,     2.479950)(     5.025000,     2.449688)(     5.040000,     2.419200)(     5.055000,     2.388488)(     5.070000,     2.357550)(     5.085000,     2.326388)(     5.100000,     2.295000)(     5.115000,     2.263388)(     5.130000,     2.231550)(     5.145000,     2.199488)(     5.160000,     2.167200)(     5.175000,     2.134688)(     5.190000,     2.101950)(     5.205000,     2.068988)(     5.220000,     2.035800)(     5.235000,     2.002388)(     5.250000,     1.968750)(     5.265000,     1.934888)(     5.280000,     1.900800)(     5.295000,     1.866488)(     5.310000,     1.831950)(     5.325000,     1.797188)(     5.340000,     1.762200)(     5.355000,     1.726988)(     5.370000,     1.691550)(     5.385000,     1.655888)(     5.400000,     1.620000)(     5.415000,     1.583888)(     5.430000,     1.547550)(     5.445000,     1.510988)(     5.460000,     1.474200)(     5.475000,     1.437188)(     5.490000,     1.399950)(     5.505000,     1.362488)(     5.520000,     1.324800)(     5.535000,     1.286888)(     5.550000,     1.248750)(     5.565000,     1.210388)(     5.580000,     1.171800)(     5.595000,     1.132988)(     5.610000,     1.093950)(     5.625000,     1.054688)(     5.640000,     1.015200)(     5.655000,     0.975488)(     5.670000,     0.935550)(     5.685000,     0.895388)(     5.700000,     0.855000)(     5.715000,     0.814388)(     5.730000,     0.773550)(     5.745000,     0.732488)(     5.760000,     0.691200)(     5.775000,     0.649688)(     5.790000,     0.607950)(     5.805000,     0.565988)(     5.820000,     0.523800)(     5.835000,     0.481388)(     5.850000,     0.438750)(     5.865000,     0.395888)(     5.880000,     0.352800)(     5.895000,     0.309488)(     5.910000,     0.265950)(     5.925000,     0.222188)(     5.940000,     0.178200)(     5.955000,     0.133988)(     5.970000,     0.089550)(     5.985000,     0.044888)(     6.000000,     0.000000)
\end{pspicture} 




\end{document}
