On Jan 24, 12:47 am, Carl Witty <[email protected]> wrote:
> On Jan 23, 8:43 pm, kcrisman <[email protected]> wrote:
>
> > But this whole thread was quite helpful to review the four (!)
> > possibilities for doing evaluation: Maxima, ns, _fast_float_, and ring
> > creation. Thanks!
>
> Well, if you're making that list, you should also include Python:
>
> def f(x, y):
> return x^2 + y^2 - 1
>
Good point; maybe I really should make that list.
> Or for blazing speed,
Haha! I never thought of this.
> you should be able to put this in a notebook
> cell (untested):
>
> %cython
> def f(int x, int y):
> return x*x + y*y - 1
This really *was* the fastest in the notebook, modulo the fact that I
had to first create and evaluate the Cython cell, which negated the
advantage for my purposes. Neat, though - maybe now I can convince
all those CS students who keep telling me that without a "real"
language you might as well not program for speed. But please don't
reopen that topic...
Thanks for all contributions - very informative.
- kcrisman
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---