[Date Index]
[Thread Index]
[Author Index]
Re: Boole Function
*To*: mathgroup at smc.vnet.net
*Subject*: [mg37231] Re: Boole Function
*From*: Andrzej Kozlowski <andrzej at tuins.ac.jp>
*Date*: Thu, 17 Oct 2002 00:09:32 -0400 (EDT)
*Sender*: owner-wri-mathgroup at wolfram.com
Boole (defined in the AddOn package Calculus`Integration`) is not
written to deal with symbolic parameters. So you may do better to use
better to use the built-in UnitStep function for which Mathematica
knows more rules. In fact, if you do not mind getting an error message
you can get something like your answer by mixing UnitStep and Boole:
<< Calculus`Integration`
In[2]:=
FullSimplify[Integrate[Boole[0 < x < y < 1]*UnitStep[z - y],
{z, 0, 1}],y>0]
From In[2]:=
Integrate::region: The region defined by 0¡Âz¡Â1&&0<x<y<1&&-y+z¡Ã0 could
not be \
broken down into cylinders.
Out[2]=
-(-1+y) Boole[0<x<y<1] UnitStep[1-y]
Of course the UnitStep is not necessary since the condition y<1 is
already included in Boole, but the Integration package does not have
rules for combining Bool and UnitStep (don't forget that Boole is not a
built in function!).
If you dispense with Bool altogether you get:
In[3]:=
FullSimplify[Integrate[UnitStep[x,y-x,z-y,1-z],{z,0,1}],y>0]
Out[3]=
-(-1+y) UnitStep[x,1-y,-x+y]
Note that this expresses exactly the same condition as
(1-y)Boole[0<x<y<1].
Andrzej Kozlowski
Yokohama, Japan
http://www.mimuw.edu.pl/~akoz/
http://platon.c.u-tokyo.ac.jp/andrzej/
and also try to use proper Mathematica
On Thursday, October 17, 2002, at 03:26 AM, Janusz Kawczak wrote:
> Suppose f(x,y,z)=Boole[0<x<y<z<1]. Let's integrate this function
> over, say, z, i.e. Integrate[f[x,y,z],{z,0,1}]. One would expect to see
> the
> output like this (1-y)Boole[0<x<y<1] (or maybe simplified expression
> as an argument in the Boole function). Instead, an error appears
> (warning) that the integration cannot be performed.
>
> How to resolve this issue so it produces a desired answer?
>
> Janusz.
>
>
>
>
>
Prev by Date:
** Re: How to speed up this calculation?**
Next by Date:
**RE: grouping and averaging {x,y} pairs of data**
Previous by thread:
**Mathematica Training Course in Amsterdam**
Next by thread:
**Re: Re: Boole Function**
| |