sage: floor(sqrt(2)*sqrt(2.)/2)==1
true
sage: (sqrt(2.)*sqrt(2.)/2)==1.0
false
sage: (sqrt(2.)*sqrt(2.)/2)
1.00000000000000 sage :((2^(1/2.))== sqrt(2.))
true
sage: (((2.^(1/2))* sqrt(2.)) == 2.)
false
why it happen about approximate????
1 | initial version |
sage: floor(sqrt(2)*sqrt(2.)/2)==1
true
sage: (sqrt(2.)*sqrt(2.)/2)==1.0
false
sage: (sqrt(2.)*sqrt(2.)/2)
1.00000000000000 sage :((2^(1/2.))== sqrt(2.))
true
sage: (((2.^(1/2))* sqrt(2.)) == 2.)
false
why it happen about approximate????
2 | No.2 Revision |
sage: floor(sqrt(2)*sqrt(2.)/2)==1In the following code,
true
sage: false
true
false
why it happen about approximate????is there an approximation error?