evalb cmd

Messages in english

Modérateur : xcasadmin

compsystems
Messages : 518
Inscription : sam. févr. 04, 2017 11:34 pm
Localisation : Colombia
Contact :

evalb cmd

Message par compsystems » jeu. nov. 08, 2018 7:35 pm

Hi BP, in the following case evalb does not work.
As a suggestion, each comparison should return true/false, for the educational environment, it is better to use symbolic words than their numerical equivalents


Exercice:
x ∈ [-5,-3,-1,1]
For what values of x does the inequality x ≥ -1 is a true or false expression?

evalb( map([-5,-3,-1,1], x→ x≥-1 ) ) ↦ [0,0,1,1] ↦ [false,false,true,true]


map([-5,-3,-1,1], x→ x≥-1 ) ↦ [false,false,true,true]

in the following cases there is no consistency, sometimes true/false other 1/0

//

[[ 0 or 0],
[ 0 or 1],
[1 or 0],
[1 or 1]]



[[false],
[true],
[1],
[1]]

//

[[ 0 and 0],
[ 0 and 1],
[1 and 0],
[1 and 1]]



[[0],
[0],
[false],
[true]]

//

[[ 0 xor 0],
[ 0 xor 1],
[1 xor 0],
[1 xor 1]]



[[0],
[1],
[1],
[0]]

parisse
Messages : 5112
Inscription : mar. déc. 20, 2005 4:02 pm
Contact :

Re: evalb cmd

Message par parisse » ven. nov. 09, 2018 8:52 am

If your students understand how to use map, then certainly they can understand that 0 corresponds to false, and non 0 corresponds to true.

compsystems
Messages : 518
Inscription : sam. févr. 04, 2017 11:34 pm
Localisation : Colombia
Contact :

Re: evalb cmd

Message par compsystems » ven. nov. 09, 2018 12:07 pm

parisse a écrit :
ven. nov. 09, 2018 8:52 am
If your students understand how to use map, then certainly they can understand that 0 corresponds to false, and non 0 corresponds to true.
Hello BP, in the textbooks of mathematics the words true / false are used, and the students when starting in the computational reasoning learn their computer equivalents 1/0. But the point of this discussion is that the evalBoolean command is not operating, besides there is inconsistency in others outputs. I think that for you it is Irrelevant, because you designed GIAC to do scientific calculation or technical computation, not to teach mathematics, that is to say to make calculations where it is impractical to do them by hand or impossible manually.

Thanks

JaiMeza

Répondre