sci2for — scilab function to Fortran routine conversion
txt=sci2for(fun,nam,vtps [,lvtps])
Scilab function
character string, the name of generated subroutine
list
list
string, text of the subroutine Fortran code
The elements of the list vtps
give the type and dimensions
of the input variables of the calling sequence and lvtps
optionally gives the type and dimensions of the output variables. This
last parameter is usefull if type and/or dimension inference cannot be
able to determine the desired values.
These lists are structured as described below:
vtps(i)=list(typ,row_dim,col_dim)
where :
is a character string giving the type of the variable :
constant,integer vector or matrix
constant,double precision vector or matrix
character string
character string (row dimension)
character string (column dimension)
Fortran code
Generated code may use routines of scilab libraries and some others whose source code may be found in <SCIDIR>/util/sci2for.f
This function is just a try. Only simple function may be translated. Many function calls have not yet Fortran equivalent, to add the translation of a new function call you may define a scilab function. whose name is f_<name of function>. see <SCIDIR>/macros/sci2for/f_*.sci files for examples.
The following keywords :
work,iwork,ierr iw* iiw* ilbN (N integer)
may not appear in the function code.