FriCAS has notion of "coercion", "retraction" and "convertion". There
is a difference between them, but basically FriCAS "knows" that some
functions can be used to change types. In particular, FriCAS has
'retract' function that can change Float to Integer: it will work only
when Float happens to have integer value, otherwise will fail. In
interactive use, when types do not match FriCAS automatically tries
to inserts convertion functions to ensure type agreement. In effect,
FriCAS treats your 'g(7.0)' as 'g(retract(7.0))'. In similar spirit,
FriCAS tries to show result in narrowest possible type, that is why it
prints 'PositiveInteger'.
Note: On command line FriCAS tries very hard to change types so
that expression can be evaluated. In user defined functions
FriCAS is doing less work, but still inserts convertion like
above. In Spad language FriCAS is insterting only small number
of "obvious" coercions.
This may look not very consistent, but simply having to insert
coercions and convertions everywhere is too inconvenient for
most users, so convenience wins. In Spad you are programming
and for readability supposed to be more explicit. Function
definitions in "interpreter" are an intermediate thing.
Concering user settings: this can not be changed by normal
settings.
--
Waldek Hebisch