Dear users!
I have a problem with using package pw.mac.
------------------------------------------------------
load("pw/pw.mac")$
g(x) := pw([-inf,-x^2,0,7*x^2,inf], x,'open)$
(%i1) pwdefint( g(x), x,1,2 );
(%i2) integrate( 7*x^2, x,1,2 );
(%i3) define( F(t), pwint(g(t), t) );
(%i4) F(2)-F(1);
(%o1) 50/3
(%o2) 49/3
(%o3) F(t):=t^3
(%o4) 7
------------------------------------------------------
1) What's going on above?
Probably I use "define" in a wrong way,
getting output to %i3 & %i4 not consistent with %i1 & %i2.
Nevertheless I expected %o1=%o2.
Playing "open" option in "pw" doesn't cure the situation.
I just wanted to calculate definite intergrals of some tooth-functions
(possibly multiplied by standard functions e.g. exp).
[These integrals represent payoff functionals...]
2) Additionally, "pwint" didn't want to calculate definite integrals
(hence I'm bound to "pwdefint").
3) Finally, the webpages were I could download the desired
pw.mac package were outdated or (temporarily) out of service,
including the newest one of the author of this package.
It would be nice to have some repository for packages
under development or experimentation.
Thank you for the answers given to all my previous questions.
Excuse me if I was unaware of some points in the earlier discussion
about pw.mac.
Best regards
- Krzysztof Lesniak