Jesús,
Thanks for mentioning this to us. This same issue also exists in other simulators, like HSPICE. In HSPICE, if you try to define:
.PARAM 2func(x)='1+x'
then you get this error message:
syntax error: parameter name begins with a number, requires an alphabetic character at beginning, error occurs at or before 2func
The issue is allowing a parser to "guess" if an expression really meant to call 2func(x) or actually meant to call something like 2+func(x). The Xyce error message, as shown below with an example netlist, is admittedly less clear than other simulators. At the least, we may want to improve the .PARAM and .FUNC sections of the Xyce Reference Guide to be more clear about what legal Function and Parameter names are in Xyce.
Illegal format for number (2FUNC) in expression: 2func(P1)
For other readers this issue occurs with this example Xyce netlist. This netlist works fine if 2func is re-named to afunc.
* Xyce netlist to test function names that start with a number
.FUNC 2func(x) {1+x}
.PARAM P1=1
V1 1 0 1
R1 1 2 {2func(P1)}
R2 2 0 1
.DC V1 1 5 1
.PRINT DC V(1) V(2)
.END
--The Xyce Team