Subversion Repositories wimsdev

Rev

Rev 16120 | Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
20 reyssat 1
!set methtit2=The square of a real number is positive or zero
2
!set methtit=Positivity of a square
3
!set methenv=ZZ QQ RR
4
!set methparmtype=function
5
!set methhelp=this method add a condition of the type \(U^2 >= 0) into\
6
 the hypotheses, where \(U) is an algebraic expression of your choice.
7
 
8
!if $wims_read_parm iswordof form check
9
 !goto $wims_read_parm
10
!endif
11
 
12
!exit
13
:form
14
 One applies \(U^2 >= 0), where \(U) =
15
 !read deduc/methparm.phtml 1
16
 
17
!exit
18
:check
19
 !if / isin $methparm1
20
  error=Division is not allowed in this method!
21
  !exit
22
 !endif
23
 !read deduc/sub/simplify ($methparm1)^2
24
 !if $out=$empty
25
  error=bad_data
26
  !exit
27
 !endif
28
 sqr=$out
29
 oldobject=0
30
 newobject0=$sqr >= 0
31
 methexp=Positivity of the squre of \($methparm1)
32
 
33
 contextlist=$ct_Onlywhen $m_U represents a real number,\
34
	$ct_Always,\
35
	$ct_Onlywhen $m_U is positive or zero,\
36
	$ct_Onlywhen $m_U is an integer
37
 
38
 resultlist=$newobject0,\
39
  $sqr > 0
40
 
41
!exit
42