π
<-

[SOLVED]Function algébric-->trigonometic

Pour le TI-Basic sur Nspire

[SOLVED]Function algébric-->trigonometic

Message non lude AlexisVieira » 19 Juin 2013, 00:45

Hi, every time i want to pass a number complexe writted in algebric mode (a+bi) to trigonometric mode (p*cis(x)) i need to use the abs() and angle() function, so this afternoon i tried to make a function/program that do this 2 steps in one
something like:
Code: Tout sélectionner
Define .... trigo(x)
...
Return abs(x) *cis(angle(x))
End...

note that on my nspire i always have "cis" defined (define cis(x)=cos(x)+i*sin(x)) so the program should work even when i have the cis() defined...

if someone can help me with this...
btw, i want this to a ti-84 too...
Dernière édition par AlexisVieira le 23 Juin 2013, 18:29, édité 1 fois.
I'm Portuguese, sorry about bad English :s
Avatar de l’utilisateur
AlexisVieira
Niveau 11: LV (Légende Vivante)
Niveau 11: LV (Légende Vivante)
Prochain niv.: 25.7%
 
Messages: 213
Images: 13
Inscription: 05 Fév 2013, 16:58
Localisation: Portugal
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: 12ºAno PT

Re: Function algébric-->trigonometic

Message non lude Levak » 19 Juin 2013, 00:51

AlexisVieira a écrit:if someone can help me with this...

I cannot see any question ?
Responsable design/graphique de TI-Planet
I do not get mad at people, I just want them to learn the way I learnt.
ImageTNOC [topic][DL]
nClock [topic][DL]
HideManager [topic][DL]
ZLock [topic][DL]
Theme Editor [topic][DL]
Mes programmes
Avatar de l’utilisateur
LevakAdmin
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Prochain niv.: 98.9%
 
Messages: 6414
Images: 22
Inscription: 27 Nov 2008, 00:00
Localisation: 0x1AACC355
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: BAC+5: Epita (ING3)

Re: Function algébric-->trigonometic

Message non lude AlexisVieira » 19 Juin 2013, 00:51

Levak a écrit:
AlexisVieira a écrit:if someone can help me with this...

I cannot see any question ?


that function doesn't work... i need someone to fix it...
I'm Portuguese, sorry about bad English :s
Avatar de l’utilisateur
AlexisVieira
Niveau 11: LV (Légende Vivante)
Niveau 11: LV (Légende Vivante)
Prochain niv.: 25.7%
 
Messages: 213
Images: 13
Inscription: 05 Fév 2013, 16:58
Localisation: Portugal
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: 12ºAno PT

Re: Function algébric-->trigonometic

Message non lude Levak » 19 Juin 2013, 00:57

AlexisVieira a écrit:that function doesn't work... i need someone to fix it...

By defined everywhere, do you mean defined in MyLib ?
Are you sure the rest of the code is not usefull ?
What is the error ?
Responsable design/graphique de TI-Planet
I do not get mad at people, I just want them to learn the way I learnt.
ImageTNOC [topic][DL]
nClock [topic][DL]
HideManager [topic][DL]
ZLock [topic][DL]
Theme Editor [topic][DL]
Mes programmes
Avatar de l’utilisateur
LevakAdmin
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Prochain niv.: 98.9%
 
Messages: 6414
Images: 22
Inscription: 27 Nov 2008, 00:00
Localisation: 0x1AACC355
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: BAC+5: Epita (ING3)

Re: Function algébric-->trigonometic

Message non lude AlexisVieira » 19 Juin 2013, 01:01

Levak a écrit:
AlexisVieira a écrit:that function doesn't work... i need someone to fix it...

By defined everywhere, do you mean defined in MyLib ?
Are you sure the rest of the code is not usefull ?
What is the error ?


i want a libpub function that when i tipe file/function(2i) the nspire answer me "2cis(pi/2)"
the "..." is that "prgrm" or "function", that (bad) exemple only have that one line of code...
I'm Portuguese, sorry about bad English :s
Avatar de l’utilisateur
AlexisVieira
Niveau 11: LV (Légende Vivante)
Niveau 11: LV (Légende Vivante)
Prochain niv.: 25.7%
 
Messages: 213
Images: 13
Inscription: 05 Fév 2013, 16:58
Localisation: Portugal
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: 12ºAno PT

Re: Function algébric-->trigonometic

Message non lude Adriweb » 19 Juin 2013, 01:03

I believe that on TI's CAS, you can't make it so that that a calculation will return an expression in terms of a user-defined one.

It'd be great, though.

(At least not in non-native ways.)

MyCalcs: Help the community's calculator documentations by filling out your calculators info!
MyCalcs: Aidez la communauté à documenter les calculatrices en donnant des infos sur vos calculatrices !
Inspired-Lua.org: All about TI-Nspire Lua programming (tutorials, wiki/docs...)
My calculator programs
Mes programmes pour calculatrices
Avatar de l’utilisateur
AdriwebAdmin
Niveau 16: CC2 (Commandeur des Calculatrices)
Niveau 16: CC2 (Commandeur des Calculatrices)
Prochain niv.: 82.2%
 
Messages: 14896
Images: 1211
Inscription: 01 Juin 2007, 00:00
Localisation: France
Genre: Homme
Calculatrice(s):
MyCalcs profile
Twitter/X: adriweb
GitHub: adriweb

Re: Function algébric-->trigonometic

Message non lude Levak » 19 Juin 2013, 01:06

AlexisVieira a écrit:i want a libpub function that when i tipe file/function(2i) the nspire answer me "2cis(pi/2)"
the "..." is that "prgrm" or "function", that (bad) exemple only have that one line of code...

Oh, I see, but no you can't.
The CAS engine stops on primitives, and functions are not primitive, only stuff like cos(), sin(), exp() etc ... are.
Responsable design/graphique de TI-Planet
I do not get mad at people, I just want them to learn the way I learnt.
ImageTNOC [topic][DL]
nClock [topic][DL]
HideManager [topic][DL]
ZLock [topic][DL]
Theme Editor [topic][DL]
Mes programmes
Avatar de l’utilisateur
LevakAdmin
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Prochain niv.: 98.9%
 
Messages: 6414
Images: 22
Inscription: 27 Nov 2008, 00:00
Localisation: 0x1AACC355
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: BAC+5: Epita (ING3)

Re: Function algébric-->trigonometic

Message non lude AlexisVieira » 19 Juin 2013, 01:08

Adriweb a écrit:I believe that on TI's CAS, you can't make it so that that a calculation will return an expression in terms of a user-defined one.

It'd be great, though.

(At least not in non-native ways.)


well, i think that it's possible on the CAS oS... i was trying lots of times today and it returned me something aproximated of that that i want...
on the non-CAS it will be more complicated because it will return the angle in RAD, so the solution could be something like "angle(x)/pi" and a "pi" writte after...
I'm Portuguese, sorry about bad English :s
Avatar de l’utilisateur
AlexisVieira
Niveau 11: LV (Légende Vivante)
Niveau 11: LV (Légende Vivante)
Prochain niv.: 25.7%
 
Messages: 213
Images: 13
Inscription: 05 Fév 2013, 16:58
Localisation: Portugal
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: 12ºAno PT

Re: Function algébric-->trigonometic

Message non lude AlexisVieira » 19 Juin 2013, 01:10

Levak a écrit:
AlexisVieira a écrit:i want a libpub function that when i tipe file/function(2i) the nspire answer me "2cis(pi/2)"
the "..." is that "prgrm" or "function", that (bad) exemple only have that one line of code...

Oh, I see, but no you can't.
The CAS engine stops on primitives, and functions are not primitive, only stuff like cos(), sin(), exp() etc ... are.


and you can do that for a non-CAS nspire?

on the cas maybe i can make it displays the angle and the module on diferent lines...
I'm Portuguese, sorry about bad English :s
Avatar de l’utilisateur
AlexisVieira
Niveau 11: LV (Légende Vivante)
Niveau 11: LV (Légende Vivante)
Prochain niv.: 25.7%
 
Messages: 213
Images: 13
Inscription: 05 Fév 2013, 16:58
Localisation: Portugal
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: 12ºAno PT

Re: Function algébric-->trigonometic

Message non lude Levak » 19 Juin 2013, 01:12

AlexisVieira a écrit:on the cas maybe i can make it displays the angle and the module on diferent lines...

Like returning lists/matrices ?
Responsable design/graphique de TI-Planet
I do not get mad at people, I just want them to learn the way I learnt.
ImageTNOC [topic][DL]
nClock [topic][DL]
HideManager [topic][DL]
ZLock [topic][DL]
Theme Editor [topic][DL]
Mes programmes
Avatar de l’utilisateur
LevakAdmin
Niveau 14: CI (Calculateur de l'Infini)
Niveau 14: CI (Calculateur de l'Infini)
Prochain niv.: 98.9%
 
Messages: 6414
Images: 22
Inscription: 27 Nov 2008, 00:00
Localisation: 0x1AACC355
Genre: Homme
Calculatrice(s):
MyCalcs profile
Classe: BAC+5: Epita (ING3)

Suivante

Retourner vers Nspire-Basic

Qui est en ligne

Utilisateurs parcourant ce forum: Aucun utilisateur enregistré et 3 invités

-
Rechercher
-
Social TI-Planet
-
Sujets à la une
Ndless for CX 4.5.5 / CX II 6.2.0
Comparaisons des meilleurs prix pour acheter sa calculatrice !
"1 calculatrice pour tous", le programme solidaire de Texas Instruments. Reçois gratuitement et sans aucune obligation d'achat, 5 calculatrices couleur programmables en Python à donner aux élèves les plus nécessiteux de ton lycée. Tu peux recevoir au choix 5 TI-82 Advanced Edition Python ou bien 5 TI-83 Premium CE Edition Python.
Enseignant(e), reçois gratuitement 1 exemplaire de test de la TI-82 Advanced Edition Python. À demander d'ici le 31 décembre 2024.
Aidez la communauté à documenter les révisions matérielles en listant vos calculatrices graphiques !
12345
-
Faire un don / Premium
Pour plus de concours, de lots, de tests, nous aider à payer le serveur et les domaines...
Faire un don
Découvrez les avantages d'un compte donateur !
JoinRejoignez the donors and/or premium!les donateurs et/ou premium !


Partenaires et pub
Notre partenaire Jarrety Calculatrices à acheter chez Calcuso
-
Stats.
1879 utilisateurs:
>1863 invités
>10 membres
>6 robots
Record simultané (sur 6 mois):
43991 utilisateurs (le 10/09/2025)
-
Autres sites intéressants
Texas Instruments Education
Global | France
 (English / Français)
Banque de programmes TI
ticalc.org
 (English)
La communauté TI-82
tout82.free.fr
 (Français)