Le 31/07/2015 14:40, Collewet Guylaine a écrit :
Thank you for your answer
I am in the first case I guess (in fact the two librairies are one
atoms module and one home-made scilab contribution)
When I try to call atoms1_lib.foo() I get the error message (sorry it
is in French on my computer): L'extraction récursive n'est pas valide
dans ce contexte.
Actually, after testing with a*locally defined function*, i get as well
some issues (not this one, others).
Let's try with linspace() that is a Scilab macro defined in
elementary_functionslib:
// Scilab 5.5.2, without never previously run linspace()
-->function linspace(a,b,c)
--> disp("this is my linspace()")
-->endfunction
Warning : redefining function: linspace . Use funcprot(0)
to avoid this message
-->linspace()
this is my linspace() // OK
-->linspace(0,1,5)
this is my linspace() // OK
-->elementary_functionslib.linspace(0,1,5)
!--error 10000
linspace: Wrong number of input argument(s): 2 expected.
at line 9 of function linspace called by :
// KO: This syntax is accepted by Scilab's linspace. It should work
here. = Scilab 5' bug
// If such a bug occurs for Scilab macros, it will likely occur also for
ATOMS ones.
// Not really encouraging...
-->linspace(0,1,5)
ans =
0. 0.25 0.5 0.75 1.
// Note : the previous call loaded the elementary_functionslib
definition. It became and stands
// the current one. Since our locally redefined linspace() does not
belong to a library, it no
// longer can be called...
Results of this tests are the same with Scilab 6-alpha1.
You may try building a library with your home-made local function.
An example of HowTo is given there, using genlib() and lib() :
http://fileexchange.scilab.org/toolboxes/365000/1.0#files
Then, you could use library-resolved calls.
Samuel
_______________________________________________
users mailing list
[email protected]
http://lists.scilab.org/mailman/listinfo/users