!set title=Regla y fracciones
!if $wims_read_parm!=$empty
 !goto $wims_read_parm
!endif
oef2wims_version=3.22
language=es
leftrange=-5.000000
rightrange=5.000000
author=Bernadette Perrin-Riou
email=bpr@math.u-psud.fr
computeanswer=no
precision=1000

ansorder=r,r
varcnt=17
prevarcnt=15
postvarcnt=1
replycnt=2
choicecnt=0
conditioncnt=1
feedbackcnt=0
format=html

val1=$imagedir
val2=$confparm1
val3=$confparm2
val4=$confparm3
val5=$confparm4

!if $testcondition=yes
 !goto test
!endif
!if $status=waiting
 !exit
!endif

val6=$[rint(6)]
val7=$[rint(0)]
val8=$[rint(1)]
val9=
val10=0
val11=
!for val12 =$val7 to $val6 
val10=$[rint($val12*1)]
val13=$[rint($val12)]
val11=$val11	text blue, $val13,-1, medium,$val10
!next
tmp=!nonempty items 2,4,5,3

tmp0=!randitem $tmp
val14=$(tmp0)
tmp0=!randint  1, 10

val15=$(tmp0)
t_=!rawmath $val8*$val15/$val14
val10=!exec pari print($t_)
t_=!replace internal \( by ( in print(numerator($val10)","denominator($val10))
tmp0=!exec pari $t_

val16=$(tmp0)

!ifval $(val16[2])=1
val16= $(val16[1]),2
!endif
replytype1=numeric
replyname1=numerador
replygood1=?analyze 17
replytype2=numeric
replyname2=denominador
replygood2=?analyze 18
question=__EXECUTED_1692754_EXERCISE__

!goto stat

!exit

:question
$()Esta es una recta graduada. El punto indicado por la flecha sobre la recta tiene como abscisa el cociente de dos enteros. Se trata de	<table align="center">	<tr align="center"><td> 
!read oef/embed.phtml reply 1,6 
$() </td></tr>	<tr align="center"><td><hr> </td></tr>	<tr align="center"><td> 
!read oef/embed.phtml reply 2,6 
$()</td></tr>	</table>	<p>	<center> 
!read oef/draw.phtml 600,50 \
xrange $val7-0.1,$val6+0.1	yrange -2,2.2	hline black,0,0	arrow 2.5,0,$val6,0,10,black	parallel $val7,-0.8,$val7,0.4,1/2,0, 40, blue	parallel $val7,-0.3,$val7,0.3,1/10,0, 200, blue	parallel $val7,-0.8,$val7,0.6,1,0, 40, red	$val11	arrow $val10,2,$val10,0, 8, black	 
$()	</center>	<p>	$val9	
$()
!exit

:hint
$()
$()
!exit

:help
$()
$()
!exit

:solution
$()
$()
!exit

:postdef

!ifval round($m_reply1)=$m_reply1 
val19= 1
!else
val19=0
!endif

!exit

:feedback

!exit

:test

!ifval $val19=1 and $m_reply1/$m_reply2=$val10
 condtest1=1
!else
 condtest1=0
!endif
condname1=

!exit

:stat
vsavelist=6,7,9,10,11,17,18
embedcnt=2
