Changeset 7091:3cb8620c631a


Ignore:
Timestamp:
10/24/07 18:43:37 (6 years ago)
Author:
William Stein <wstein@…>
Branch:
default
Message:

Trac #987 (Moretti and Stein) -- Fix a critical bug found by kricsman involving parsing maxima expressions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sage/calculus/calculus.py

    r7010 r7091  
    121121        sage: float(f(pi))             # random low order bits 
    122122        6.1232339957367663e-16 
     123 
     124    Another example: 
     125        sage: f = integrate(1/sqrt(9+x^2), x); f 
     126        asinh(x/3) 
     127        sage: f(3) 
     128        asinh(1) 
     129        sage: f.diff(x) 
     130        1/(3*sqrt(x^2/9 + 1)) 
    123131 
    124132COERCION EXAMPLES: 
     
    51085116                j = msg.rfind("'") 
    51095117                nm = msg[i+1:j] 
    5110                 syms[nm] = var(nm) 
     5118 
     5119                res = re.match(nm + '\s*\(.*\)', s) 
     5120                if res: 
     5121                    syms[nm] = function(nm) 
     5122                else: 
     5123                    syms[nm] = var(nm)                     
    51115124            else: 
    51125125                break 
Note: See TracChangeset for help on using the changeset viewer.