MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Re: Re: integration of piecewise convex bivariate function with 6 parameters

  • To: mathgroup at smc.vnet.net
  • Subject: [mg79133] Re: [mg79098] Re: [mg78965] Re: integration of piecewise convex bivariate function with 6 parameters
  • From: "Michael Chen" <vancouver.michael at gmail.com>
  • Date: Thu, 19 Jul 2007 03:35:10 -0400 (EDT)
  • References: <71ab86070707162318s287cb149meb911f880ea53e3c@mail.gmail.com>

Thanks, Maxim,

I used both PiecewiseIntegrate and Integrate to calculate my piecewise
integral problem. And PiecewiseIntegrate generated much tidy expression,
though still lengthy than my manual result. The speed of PiecewiseIntegrate
is also faster than Integrate, <10 seconds vs >100 seconds.

I am not sure how to express this problem using PiecewiseIntegrate though.
If using Integrate, the problem is like this:
NIntegrate[c.(h-x) Boole[A.(h-x) >= 0], {h1, B1, U1}, {h2, B2, U2}, ....,
{hn,Bn,Un}] ,
where c, A, B, U are reals, x is parameter vector, and h is random vector,
so the result shall be a piecewise function in x.

One more thing, in the manual of PiecewiseIntegrate, it is said that  in
Mathematica 5, the Reduce doesn't always partition the domain into disjoint
subsets, and hence PiecewiseIntegrare might double count. I am wondering
whether or not this is an issue in Mathematica 6.

Thanks so much for the community. This is my third day of using Mathematica,
and I am very happy!

Michael Chen


On 7/18/07, Maxim <m.r at inbox.ru> wrote:
>
>
>
> -----Original Message-----
> From: "Michael Chen" <vancouver.michael at gmail.com>
> To: "m.r at inbox.ru" < m.r at inbox.ru>
> Date: Tue, 17 Jul 2007 01:18:10 -0500
> Subject: [mg79098] Re: [mg78965] Re: integration of piecewise convex
> bivariate function with 6 parameters
>
> >
> > Thanks Maxim, I cannot follow the installation instruction on my version
> 6
> > though. There is no "File->Save as Special->Package Format". I did
> copied
> > the code as pure text, but have no clue what to do next. Would you
> please
> > give more details? Thanks.
> >
> > Michael Chen
> >
>
> Michael,
>
> select File|Save As and then select Mathematica Package (*.m) in the 'Save
> as type' field. It will automatically comment out everything except the
> initialization cell.
>
> Maxim
>
>
>



  • Prev by Date: Re: Coding an inverse permutation
  • Next by Date: Re: Coding an inverse permutation
  • Previous by thread: Re: Re: integration of piecewise convex bivariate function with 6 parameters
  • Next by thread: LocatorPane problem