2009/12/14 Robert Bradshaw <rober...@math.washington.edu> > On Dec 14, 2009, at 12:15 PM, Dag Sverre Seljebotn wrote: > > > Robert Bradshaw wrote: > >> On Dec 14, 2009, at 11:43 AM, Carlos Córdoba wrote: > >> > >>> I have to agree with Marshall, because it could be confusing for new > >>> sage users that come from python to see such a different syntax > >>> meaning. > >>> > >>> But what about the Mathematica syntax? Could it be adopted by sage? > >> > >> The Mathematica syntax is (in my opinion) much less Pythonic than > >> using "->" in this context, even if the latter will have another > >> meaning in Python 3. > > > > Does the CAS syntax really mean Python "lambda" though? > > Thanks for bringing up this point. No it doesn't, and shouldn't if we > adopt this syntax. > > - Robert >
Correct me if I'm wrong but I believed that the definition f(x) = x^2 as a symbolic function it's only possible in sage. Anyway, the use of anonymous functions is mostly useful on constructs that operate over lists, like map and reduce. In 10 years of using Mathematica I've ever needed to derive this kind functions, but nevertheless I've checked if it's possible, and indeed it is, for example D[(#^2)&[x], x] gives 2*x. > > > I would think > > that using -> in Maple would define something symbolic which one could > > manipulate...more like an anonymous > > > > f(x) = x**2 > > > > than "lambda x: x**2". For the latter one cannot find symbolic > > derivatives and so on. > > > -- > To post to this group, send email to sage-support@googlegroups.com > To unsubscribe from this group, send email to > sage-support+unsubscr...@googlegroups.com<sage-support%2bunsubscr...@googlegroups.com> > For more options, visit this group at > http://groups.google.com/group/sage-support > URL: http://www.sagemath.org > -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org