Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#939 subscripted additive functions

open
nobody
5
2006-09-08
2006-06-02
Barton Willis
No

(%i1) declare(f,additive)$

(%i2) f[a+b](x);
Improper name or value in functional position:
f[b]+f[a]

Yeechs! The function 'f' is additive in its
subscript:

(%i3) f[a+b];
(%o3) f[b]+f[a]

Surely, a subscripted additive function shouldn't be
additive in its subscript.

Barton

Discussion

  • Robert Dodier
    Robert Dodier
    2006-06-05

    Logged In: YES
    user_id=501686

    I agree that subscripted functions should not be additive in
    their subscripts, but in Maxima the same notation is used
    for subscripted functions as for memoizing functions, and
    there's no reason to rule out additive memoizing functions.
    (Or is there?)

    I suppose F[a + b](x + y) must be a subscripted function
    call, but F[a + b] could be either a memoizing function
    call, or a subscripted function. Even in the case of F[a +
    b](x + y) could be the return value of a memoizing function
    applied to x + y.

     
  • Robert Dodier
    Robert Dodier
    2006-06-05

    • labels: --> 460522
     
  • Robert Dodier
    Robert Dodier
    2006-09-08

    • labels: 460522 --> Lisp Core - Simplification