# [Maxima] tellsimp problem

Richard Hennessy rvh2007 at comcast.net
Sat Oct 25 20:44:36 CDT 2008

```This is cool.  It is more than I was trying to achieve but I would like to have it anyway.  The link on the email is no
longer valid.  Is there another link to pmint.mac.

Thanks,

Rich

----- Original Message -----
From: "Barton Willis" <willisb at unk.edu>
To: "Richard Hennessy" <rvh2007 at comcast.net>
Cc: "Maxima List" <maxima at math.utexas.edu>
Sent: Saturday, October 25, 2008 9:02 PM
Subject: Re: [Maxima] tellsimp problem

to find antiderivatives of functions that involve the unit_step,
here is one approach:

(%i15) put(abs, [lambda([u], u), true], 'darboux_poly)\$
(%i17) myintegrate(f,x) := pmint(subst('unit_step = lambda([s], (s + abs
(s))/(2*s)), f),x)\$

(%i27) myintegrate(unit_step(x),x);
(%o27) (x^3*abs(x)+x^4)/(2*x^2*abs(x))

(%i31) myintegrate(unit_step(x^2-1),x);
(%o31) (x^5*abs(x^2-1)-2*x^3*abs(x^2-1)+x*abs
(x^2-1)+x^3*(x^2-1)^2-x*(x^2-1)^2)/(2*(x^2-1)^2*abs(x^2-1))

(%i32) myintegrate(exp(x) * unit_step(x-1),x);
(%o32) (x^2*%e^x*abs(x-1)-2*x*%e^x*abs(x-1)+%e^x*abs(x-1)+
(x-1)^2*x*%e^x-(x-1)^2*%e^x)/(2*(x-1)^2*abs(x-1))

The message

http://www.math.utexas.edu/pipermail/maxima/2008/012535.html

has a link to a location of pmint.mac.

Barton

```