!!! fichier de traitement des exercices 1,2 et 3 !!!

!if $niv<3
  fcm1TF=!exec maxima ratsimp(ev($fcm,m=$c1)-($r1));
  !if $fcm1TF>=0
    mono=1
    vrep=1
    note=10
   !else
    mono=0
    vrep=0
    note=0
  !endif
!endif

!if $niv=3
  fcm1TF1=!exec maxima ratsimp(ev($fcm,m=$c1)-($r1));
  fcm1TF2=!exec maxima ratsimp(ev($fcm,m=$c1)-($r2));
  
  !if $fcm1TF1>=0 and $fcm1TF2<0
    vrep=1
    mono=1
    note=10
  !endif
  
  !if $fcm1TF2>=0
    vrep=0
    mono=2
    note=0
  !endif
  
  !if $fcm1TF1<0
    vrep=0
    mono=0
    note=0
  !endif
!endif
  
module_score=$note
!read answer.phtml
status=done
!exit
