Re: [Scilab-users] Help me plot y = x^(1/3);

2018-03-09 Thread Dang Ngoc Chan, Christophe
Hello Hector,

> De : Hector R. Lepez
> Envoyé : vendredi 9 mars 2018 13:58
>
> What does it mean to put a sign (x) * ??

You'll find some answers here:

https://help.scilab.org/docs/6.0.1/en_US/sign.html

https://help.scilab.org/docs/6.0.1/en_US/hat.html

https://help.scilab.org/docs/6.0.1/en_US/dot.html

Regards

--
Christophe Dang Ngoc Chan
Mechanical calculation engineer
This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received this e-mail in error), please 
notify the sender immediately and destroy this e-mail. Any unauthorized 
copying, disclosure or distribution of the material in this e-mail is strictly 
forbidden.
___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] Help me plot y = x^(1/3);

2018-03-09 Thread Hector R. Lepez
 This solution worked, could you explain how you put it together? What does it 
mean to put a sign (x) * ?? Thank you

Héctor Lépez Cel: 154137337 

El viernes, 9 de marzo de 2018 09:25:18 ART, Stéphane Mottelet 
 escribió:  
 
  Le 09/03/2018 à 11:57, Hector R. Lepez a écrit :
  
   I have problems to graph the function

x=[-10:1:10]

y = x^(1/3);

plot(x,y);

the same in plot of google gives a graph but scilab does anything with the 
sign.  
  Héctor Lépez
  
  
 ___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users
 
 
By default in scilab non-integer power elevation of negative number is made in 
the complex domain. The particular case of the real cubic root can be treated 
like this :
 
y = sign(x).*abs(x)^(1/3);
 
otherwise (-1)^(1/3) gives you one of the complex cubic root of -1, namely 
exp(%i*%pi*1/3)
 
 
S.
 
 -- 
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
http://www.utc.fr/~mottelet ___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users
  ___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] Help me plot y = x^(1/3);

2018-03-09 Thread CRETE Denis
Hello,

The operator ^ seems to return the real part of one of the complex roots of 
x^3=1.
If x=[-10:1:10]
and
y = x^(1/3);
Thus, for x<0, the values of y are half the opposite of values obtained with 
x>0.
With y=x.^(1/3), the values of y are complex for x<0.
HTH
Denis
De : users [mailto:users-boun...@lists.scilab.org] De la part de Hector R. Lepez
Envoyé : vendredi 9 mars 2018 11:58
À : users@lists.scilab.org
Objet : [Scilab-users] Help me plot y = x^(1/3);

I have problems to graph the function

x=[-10:1:10]

y = x^(1/3);

plot(x,y);

the same in plot of google gives a graph but scilab does anything with the sign.

Héctor Lépez
___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] Help me plot y = x^(1/3);

2018-03-09 Thread Stéphane Mottelet

Le 09/03/2018 à 11:57, Hector R. Lepez a écrit :

I have problems to graph the function
x=[-10:1:10] y = x^(1/3); plot(x,y); the same in plot of google gives 
a graph but scilab does anything with the sign.


Héctor Lépez


___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


By default in scilab non-integer power elevation of negative number is 
made in the complex domain. The particular case of the real cubic root 
can be treated like this :


y = sign(x).*abs(x)^(1/3);

otherwise (-1)^(1/3) gives you one of the complex cubic root of -1, 
namely exp(%i*%pi*1/3)


S.

--
Stéphane Mottelet
Ingénieur de recherche
EA 4297 Transformations Intégrées de la Matière Renouvelable
Département Génie des Procédés Industriels
Sorbonne Universités - Université de Technologie de Compiègne
CS 60319, 60203 Compiègne cedex
Tel : +33(0)344234688
http://www.utc.fr/~mottelet

___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users