Page 1 sur 1

TImode versus Xcas mode

Publié : mar. août 08, 2017 12:24 pm
par compsystems
What is the difference of TImode (89/92) versus Xcas mode?

I only notice that the output of the solvers are algebraic expressions and not lists of solutions

Xcas mode
1: solve([ y = x^2, y = 2*x + 3 ],[x,y]) [enter] returns
[[3,9],[-1,1]]

TImode (89/92)
1: solve([ y = x^2, y = 2*x + 3 ],[x,y]) [enter] returns
(x=3) and (y=9)) or ((x=-1) and (y=1)

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 6:08 am
par parisse
Indices start at 1, the parser also accepts some ti syntaxes that are not accepted otherwise (for programming).

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 4:18 pm
par compsystems
ok

Image

Within a program with which command to set these modes?

cmd(tiMode/xcasMode)

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 4:44 pm
par parisse
xcas_mode(0) (default) or xcas_mode(3) (TI)

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 8:09 pm
par compsystems
Ideas

To be able to restore the configuration mode for sotfware and not by hand, please add the option xcas_mode(-1), as it does autosimplify(-1)

xcas_mode(-1) [enter] returns current xcasmode [0 or 1 or 2 or 3]

And when exe xcas_mode(0 or 1 or 2 or 3) , returns the keyword Done as alias of 1, and not 1 because is the output associated with the mode 1=Maple



samples:

1:
xcas_mode(0) [enter] returns
"Warning: some commands like subs might change arguments order"
Done

2:
xcasModeFlag:=xcas_mode(-1) [enter] returns
0

...

3:
xcas_mode(3) [enter] returns
"Warning: some commands like subs might change arguments order"
Done

4:
xcas_mode(xcasModeFlag) // restore the previous xcas mode

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 8:29 pm
par parisse
xcas_mode() returns the current mode, you can save yourself the current mode before changing it, then you can restore it later.

Re: TImode versus Xcas mode

Publié : mer. août 09, 2017 8:35 pm
par compsystems
ok

The output of xcas_mode (#) is currently a string of text, I think it is better to return a confirmation output of change 1 or Done and the warning message in between the cmd and output

Re: TImode versus Xcas mode

Publié : jeu. août 10, 2017 4:37 pm
par compsystems
related

That returns autosimplify() and autosimplify(-1)?

case 1:
autosimplify(0) -> 1
autosimplify() -> 1
autosimplify(-1) -> 'Nop'

case 2:
autosimplify(1) -> 1
autosimplify() -> 1
autosimplify(-1) -> 'regroup'

case 3:
autosimplify(2) -> 1
autosimplify() -> 1
autosimplify(-1) -> 'simplify'

case 4:
autosimplify(3) -> 'simplify'
autosimplify() -> 1
autosimplify(-1) -> 'simplify'

Re: TImode versus Xcas mode

Publié : jeu. août 10, 2017 5:12 pm
par parisse
I will modify autosimplify() to return the command used.

Re: TImode versus Xcas mode

Publié : jeu. août 10, 2017 8:45 pm
par compsystems
parisse a écrit :I will modify autosimplify() to return the command used.
thanks

Input
(string, explicit input)
autosimplify('Nop' / 'regroup' / 'simplify' ) -> Done

(numeric input)
autosimplify(0 / 1 / 2 ) -> Done

output
autosimplify() -> 0 / 1 / 2 (numeric output)
autosimplify(-1) -> 'Nop' / 'regroup' / 'simplify' (string, explicit output)


same for xcas_mode()

Input
(numeric input)
xcas_mode(1 / 0 ) -> Done

output
xcas_mode() -> 0 / 1 / 2 / 3 (numeric output)
xcas_mode(-1) -> 'Xcas' / 'Maple' / 'Mupad' / 'TI' (string, explicit output)

Re: TImode versus Xcas mode

Publié : ven. août 11, 2017 6:48 pm
par compsystems
Hi, Bernard.

I think I've already mentioned it, I'm doing an educational research project with CAS, and I'm using Xcas for the experiment, my intention in some improvements or aesthetic changes, is for the purpose of favoring or facilitating the use in the interface especially of Undergraduate students, for this reason my suggestions

The arguments 0/1/2 are not very explicit, I see that the command autosimplify accepts numerical arguments as symbolic, the complex_mode command only accepts 'complex' please add 'Nop' as arg

Thanks

Image

Re: TImode versus Xcas mode

Publié : sam. août 12, 2017 4:58 am
par parisse
I don't understand what complex_mode('Nop') would mean. Moreover, students will certainly change complex mode with the interface, not with a command, unless they are sufficiently advanced to understand how to do it properly.