#12289: pass algorithm argument to custom numeric evalution methods
-------------------------------------------------+--------------------------
Reporter: burcin | Owner: burcin
Type: enhancement | Status: needs_work
Priority: major | Milestone: sage-5.11
Component: symbolics | Resolution:
Keywords: pynac sd35.5 sd40.5 sd48 | Work issues: doctests,
documentation
Report Upstream: N/A | Reviewers: Karl-Dieter
Crisman, Doug S. MacNeil, Benjamin Jones
Authors: Burcin Erocal, Benjamin Jones | Merged in:
Dependencies: | Stopgaps:
-------------------------------------------------+--------------------------
Comment (by kcrisman):
Okay, everything fixed except a segfault on beta which is exactly the same
one which
[http://trac.sagemath.org/sage_trac/attachment/ticket/9130/trac_9130-py_float_segfault.take2.patch
this] fixed. Burcin says that this needs to be handled properly and so
{{{
static ex beta_evalf(const ex & x, const ex & y, PyObject* parent)
{
if (is_exactly_a<numeric>(x) && is_exactly_a<numeric>(y)) {
try {
return
exp(lgamma(ex_to<numeric>(x))+lgamma(ex_to<numeric>(y))-lgamma(ex_to<numeric>(x+y)));
} catch (const dunno &e) { }
}
return beta(x,y).hold();
}
}}}
in ginac/inifcns_gamma.cpp needs to be worked on in addition to other
stuff.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12289#comment:21>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/groups/opt_out.