#1773: piecewise functions and integration / arithmetic do not play well
together
----------------------------+------------------------
Reporter: was | Owner: gfurnish
Type: defect | Status: new
Priority: major | Milestone: sage-7.3
Component: calculus | Resolution:
Keywords: | Merged in:
Authors: | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: #14801 | Stopgaps:
----------------------------+------------------------
Comment (by rws):
The problem on first sight here is that operations on `piecewise` do not
get translated to what is expected, i.e., squaring the pieces. Also it
seems that Maxima does not convert them, nor is it considering loading
`pw.mac` without which it simply knows nothing about piecewise functions.
So we must either load this package when encountering `piecewise` in the
Maxima interface then convert, or the expression must be simplified, i.e.,
the operations applied piecewise, probably by Pynac. Or both.
Of course, the `integral` member function is accessible with pure
`piecewise` objects:
{{{
sage: tri_wave1 = piecewise([ [(-1,1), f1^2], [(1,3), f2^2]])
sage: tri_wave1.integral(definite=True)
4/3
}}}
--
Ticket URL: <https://trac.sagemath.org/ticket/1773#comment:14>
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 https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.