!set title=Raíz cuadrada de una matriz 2x2
!if $wims_read_parm!=$empty
 !goto $wims_read_parm
!endif
oef2wims_version=3.22
language=en
author=XIAO Gang
email=xiao@unice.fr
leftrange=-5.000000
rightrange=5.000000
precision=10000

ansorder=r,r,r,r
varcnt=11
prevarcnt=10
postvarcnt=0
replycnt=4
choicecnt=0
conditioncnt=2
feedbackcnt=0
format=tex

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

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

val6=A
val7=I
tmp0=!randint 1, 9

tmp1=!randitem -1,1

val8=$[rint($(tmp0)*$(tmp1))]
tmp0=!randint 1, 9

tmp1=!randitem -1,1

val9=$[rint($(tmp0)*$(tmp1))]
tmp0=!randint 1, 9

tmp1=!randitem -1,1

val10=$[rint($(tmp0)*$(tmp1))]
tmp0=!randint 1, 9

tmp1=!randitem -1,1

val11=$[rint($(tmp0)*$(tmp1))]
val12=$[rint($val8*($val8)+($val9)*($val10))]
val13=$[rint(($val8+($val11))*($val9))]
val14=$[rint(($val8+($val11))*($val10))]
val15=$[rint(($val11)^2+($val9)*($val10))]
replyname1=<i>a</i>
replygood1=?analyze 16
replyname2=<i>b</i>
replygood2=?analyze 17
replyname3=<i>c</i>
replygood3=?analyze 18
replyname4=<i>d</i>
replygood4=?analyze 19
question=!nosubst Encontrar una matriz &#36;A=\pmatrix{a&b\cr c&d}&#36;	tal que	&#36;&#36; A^2 = \pmatrix{$val12&$val13\cr$val14&$val15}, &#36;&#36;	sabiendo que	&#36;a, b, c, d&#36; son no nulas.	

!goto stat

!exit

:hint
$()
$()
!exit

:help
$()
$()
!exit

:solution
$()
$()
!exit

:feedback

!exit

:test

!ifval ($val16)^2+($val17)*($val18)=$val12 and $val17*($val16+($val19))=$val13 and	 $val18*($val16+($val19))=$val14 and ($val19)^2+($val17)*($val18)=$val15
 condtest1=1
!else
 condtest1=0
!endif
condname1=Con estos valores A^2 es la matriz dada

!ifval $val16*($val17)*($val18)*($val19)!=0 and floor($val16)=$val16 and floor($val17)=$val17 and	floor($val18)=$val18 and floor($val19)=$val19
 condtest2=1
!else
 condtest2=0
!endif
condname2=a,b,c,d son enteros no nulos

!exit

:stat
vsavelist=12,13,14,15,16,17,18,19
embedcnt=0
