Re: [Scilab-users] function with more result variables, how?

2017-02-13 Thread Erhy
Thank you Samuel!
Erhy



--
View this message in context: 
http://mailinglists.scilab.org/function-with-more-result-variables-how-tp4035470p4035476.html
Sent from the Scilab users - Mailing Lists Archives mailing list archive at 
Nabble.com.
___
users mailing list
users@lists.scilab.org
http://lists.scilab.org/mailman/listinfo/users


Re: [Scilab-users] function with more result variables, how?

2017-02-12 Thread Samuel Gougeon

Le 12/02/2017 à 23:34, Erhy a écrit :

Hello!
I declared a function
e.g.
function [ DifT, FByReal, FR ] = MyXYZ(koeff)
DifT = 33.0; FByReal = [ 1.0 , 55.7 ]; FR = [ 1 2 3; 4 5 6; 7 8 9; 10 -11
-12 ];
endfunction

but only the first result is delivered.

In help:  stands for the output argument list.

How to have more result variables with different type*?*

Thank you
Erhy



I get:
--> function [ DifT, FByReal, FR ] = MyXYZ(koeff)
  > DifT = 33.0;
  > FByReal = [ 1.0 , 55.7 ];
  > FR = [ 1 2 3; 4 5 6; 7 8 9; 10 -11 -12 ];
  > endfunction

--> [a,b,c] = MyXYZ(1)
 c  =
   1.2.3.
   4.5.6.
   7.8.9.
   10.  -11.  -12.

 b  =
   1.   55.7

 a  =
   33.

All is right.

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