Integral containing 1/(a+b*x+c*sqrt(d-x^2))^2

  • Thread starter Thread starter Wu Xiaobin
  • Start date Start date
  • Tags Tags
    Integral
Click For Summary

Homework Help Overview

The discussion revolves around the integration of a joint probability density function to derive its marginal probability density function. The problem involves complex expressions with square roots and quadratic terms, situated within the context of probability theory and calculus.

Discussion Character

  • Exploratory, Mathematical reasoning, Assumption checking

Approaches and Questions Raised

  • Participants explore rewriting the integrand in different forms, such as using partial fractions and identifying quadratics. There are attempts to simplify the integration process through variable substitutions and discussions about the complexity of roots involved in the integration.

Discussion Status

The discussion is ongoing, with participants providing hints and suggestions for tackling the integration. Some express confusion regarding the use of partial fractions and the complexity of the roots, while others propose keeping the roots in symbolic form to facilitate integration.

Contextual Notes

Participants note the challenges posed by the complicated forms of the roots and the lengthy nature of the resulting expressions from integration. There is also mention of specific numerical values for parameters that may affect the integration process.

Wu Xiaobin
Messages
25
Reaction score
0
Thank you so much if anyone can solve this integral to obtain its individual marginal PDF.

The joint probability density function shows as follows:
f(\xi_1,\xi_2)=\frac{1-\eta_1^2-\eta_2^2-\eta_3^2}{4\pi}[\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2-\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}+\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2+\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}]
with the domain of integration 0\leq(\xi_1^2+\xi_2^2\leq1)

And I want to integrate the above joint probability density function to obtain f(\xi_1)
 
Physics news on Phys.org
Writing the denominators as (A-Bx±C√(D2-x2))2, I believe the integrand reduces to ##\frac{f+g}{\left(f-g\right)^2} ## where f = (A-Bx)2 and g = C2(D2-x2). Maybe you can usefully expand that with partial fractions.
 
Thanks for your reply, I will have a try.
 
haruspex said:
Writing the denominators as (A-Bx±C√(D2-x2))2, I believe the integrand reduces to ##\frac{f+g}{\left(f-g\right)^2} ## where f = (A-Bx)2 and g = C2(D2-x2). Maybe you can usefully expand that with partial fractions.

Could you please give some more hint. I am confused about using partial fractions.
 
Wu Xiaobin said:
Could you please give some more hint. I am confused about using partial fractions.
In what I posted before, f and g are quadratics in x. So f-g is a quadratic; suppose it has roots α, β. Then we have ##\frac{f+g}{(x-\alpha)^2(x-\beta)^2}##. It should be possible to write this as a sum of fractions in which the numerators are all constants and the denominators are (x-α), (x-α)2, (x-β), (x-β)2. To find the numerators, just fill them in as four unknowns, equate the sum to the original integrand, multiply out, then collect up terms according to the powers of x. That should produce four equations, one for each power of x.
 
Wu Xiaobin said:
Thank you so much if anyone can solve this integral to obtain its individual marginal PDF.

The joint probability density function shows as follows:
f(\xi_1,\xi_2)=\frac{1-\eta_1^2-\eta_2^2-\eta_3^2}{4\pi}[\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2-\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}+\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2+\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}]
with the domain of integration 0\leq(\xi_1^2+\xi_2^2\leq1)

And I want to integrate the above joint probability density function to obtain f(\xi_1)

You have
f = c\left[ \frac{1}{A - \sqrt{B}}+ \frac{1}{A + \sqrt{B}} \right],
where A = linear and B = quadratic in ##(\xi_1,\xi_2)## . Adding the fractions gives
f = c \frac{2A}{A^2 - B} = \frac{\text{linear}}{\text{quadratic}},
whose indefinite ##\xi_2## integration is do-able in terms of log and arctan functions.
 
haruspex said:
In what I posted before, f and g are quadratics in x. So f-g is a quadratic; suppose it has roots α, β. Then we have ##\frac{f+g}{(x-\alpha)^2(x-\beta)^2}##. It should be possible to write this as a sum of fractions in which the numerators are all constants and the denominators are (x-α), (x-α)2, (x-β), (x-β)2. To find the numerators, just fill them in as four unknowns, equate the sum to the original integrand, multiply out, then collect up terms according to the powers of x. That should produce four equations, one for each power of x.

Thank you so much for your further reply.
However when I work it out in Mathematica, the root appears rather complicated. Two of the roots are
<br /> \alpha,\beta=\frac{\eta_2-\xi_1\eta_1\eta_2\pm\sqrt{-\eta_3^2(1-2\xi_1\eta_1-\eta_2^2-\eta_3^2+\xi_1^2(\eta_1^2+\eta_2^2+\eta_3^2))}}{\eta_{2}^{2}+\eta_3^2}<br />

It appears to be it would be rather complex to derive the four fractions.
 
Ray Vickson said:
You have
f = c\left[ \frac{1}{A - \sqrt{B}}+ \frac{1}{A + \sqrt{B}} \right],
where A = linear and B = quadratic in ##(\xi_1,\xi_2)## . Adding the fractions gives
f = c \frac{2A}{A^2 - B} = \frac{\text{linear}}{\text{quadratic}},
whose indefinite ##\xi_2## integration is do-able in terms of log and arctan functions.

Excuse me. I wonder you may neglect the square in the integral?
 
I got the result as follows, but I still can't work it out.
I hope if anyone could help.
<br /> f(\xi_1)=\frac{(1-\eta_1\xi_1)(1-\eta_1^2-\eta_2^2-\eta_3^2)}{2[(1-\eta_1\xi_1)^2-(\eta_2^2+\eta_3^2)(1-\xi_1^2)]^{3/2}}<br />
where the domain of integration is -1\leq \xi_1\leq 1
 
  • #10
By suitable change of variable, you should be able to get that into the form ##\frac{\left(x+A\right)dx}{\left(x^2+B^2\right)^{3/2}}##. The x term in the numerator is easy: 2x.dx =d(x2), allowing direct integration. That leaves ##\frac{dx}{\left(x^2+B^2\right)^{3/2}}##. Put x = Btan(θ).
 
  • #11
haruspex said:
By suitable change of variable, you should be able to get that into the form ##\frac{\left(x+A\right)dx}{\left(x^2+B^2\right)^{3/2}}##. The x term in the numerator is easy: 2x.dx =d(x2), allowing direct integration. That leaves ##\frac{dx}{\left(x^2+B^2\right)^{3/2}}##. Put x = Btan(θ).
I put the result f(\xi_1) here but I am not able to obtain f(\xi_1).
The question is I can't obtain f(\xi_1) from integrating f(\xi_1,\xi_2) with respect to \xi_2

I found it too difficult to obtain the partial fractions and it's hard to integrate to obtain f(\xi) in the form I put.
 
  • #12
Wu Xiaobin said:
I put the result f(\xi_1) here but I am not able to obtain f(\xi_1).
Oh, ok, I misunderstood your previous post.
Can you just keep the roots as α, β and finish the integration, then substitute in at the end? You might find there's a lot of cancellation, e.g. you can easily substitute for α+β.
 
  • #13
haruspex said:
Oh, ok, I misunderstood your previous post.
Can you just keep the roots as α, β and finish the integration, then substitute in at the end? You might find there's a lot of cancellation, e.g. you can easily substitute for α+β.

But how can I use \alpha,\beta without taking its real form into consideration. Just as I put in the previous message, it has quite complicate form.

I am not very good at it, could you show me just how to use \alpha,\beta to obtain the partial fraction. Of course I will solve the integration my self. Please tell me how to carry on.
 
  • #14
Wu Xiaobin said:
Excuse me. I wonder you may neglect the square in the integral?

Sorry: I did not see the "square".
 
  • #15
Wu Xiaobin said:
But how can I use \alpha,\beta without taking its real form into consideration. Just as I put in the previous message, it has quite complicate form.

I am not very good at it, could you show me just how to use \alpha,\beta to obtain the partial fraction. Of course I will solve the integration my self. Please tell me how to carry on.

You can write
\frac{1}{(x - \alpha)(x-\beta)} = \frac{c_1}{x-\alpha} + \frac{c_2}{x-\beta}, where ##c_1, \, c_2## are easily expressible in terms of ##\alpha, \, \beta##. Thus,
\left[ \frac{1}{(x - \alpha)(x-\beta)} \right]^2 =<br /> \left[ \frac{c_1}{x-\alpha} + \frac{c_2}{x-\beta} \right]^2,
which involves ##1/(x - \alpha)^2, \; 1/(x - \beta)^2## and ##1/[(x-\alpha)(x-\beta)]##. Re-write the latter again in terms of just ##1/(x-\alpha)## and ##1/(x-\beta)##. In the end you will have a function of the form
f = \frac{a_1}{x-\alpha} + \frac{b_1}{(x - \alpha)^2}<br /> + \frac{a_2}{x - \beta} + \frac{b_2}{(x - \beta)^2} + c + px + qx^2,
where ##x = \xi_2## and the coefficients ##a_i, b_i , c, p, q ## and ##\alpha, \, \beta## are all functions of ##\xi_1##. You can then do the integral.

Using this method to compute
f(\xi_1) = \int_{-\sqrt{1-\xi_1^2}}^{\sqrt{1-\xi_1^2}} f(\xi_1,\xi_2) \, d \xi_2,
Maple gives an answer that takes between 25 and 26 pages to display when everything is written out in terms of the ##\eta_i.## So, the final result is long and messy.
 
Last edited:
  • #16
Ray Vickson said:
So, the final result is long and messy.
Yet, if I understand Wu Xiaobin's post, the answer is supposed to be as in post #9.
 
  • #17
haruspex said:
Yet, if I understand Wu Xiaobin's post, the answer is supposed to be as in post #9.

I do not believe the answer in post #9. I input input some numerical values of the eta_i and tackled the integration for f(xi_1) directly, numerically; that is, for each numerical value of xi_1, I can do the xi_2 integral numerically. I plotted f(xi_1) and compared it with the formula in #9. The shapes are different. (All computations done in Maple.)
 
  • #18
Ray Vickson said:
Sorry: I did not see the "square".

That is fine.
 
  • #19
Ray Vickson said:
So, the final result is long and messy.

Yeah, I see. If I strive to work it out in partial fraction, I believe the result would be messy.
However I have tried another method and it works out.

I would post here later.
 
  • #20
haruspex said:
Yet, if I understand Wu Xiaobin's post, the answer is supposed to be as in post #9.

You are right. The result is displayed in post #9.

Last night I worked it out with your kind help. I would posted here later.

It would take me a little time to check.
 
  • #21
Wu Xiaobin said:
You are right. The result is displayed in post #9.

Last night I worked it out with your kind help. I would posted here later.

It would take me a little time to check.

No, the correct result is NOT displayed in post #9. Just look at the formula. The actual f(xi_1) is given by
f(\xi_1) = \int_{-\sqrt{1-\xi_1^2}}^{\sqrt{1-\xi_1^2}} f(\xi_1, \xi_2)\, d\xi_2, \; -1 \leq \xi_1 \leq 1.
As ##\xi_1 \to \pm 1## this → 0 because we have an integral from 0 to 0. However, the formula in post #9 gives nonzero results at ##\xi_1 = \pm 1##.
 
Last edited:
  • #22
Thank you so much for all friends who replied.

I think I have worked it out, but maybe using another way to solve it.
However partial fractions really help when I solve this problem.

I needs great effort to type the integration process here, so I decide to attach the pdf
document here.

The attachment shows the whole process of solving the integral.

In the end, I want to give me special gratitude to haruspex and Ray Vickson.

--
Best regards
Jacky Wu
 

Attachments

  • #23
Wu Xiaobin said:
Thank you so much for all friends who replied.

I think I have worked it out, but maybe using another way to solve it.
However partial fractions really help when I solve this problem.

I needs great effort to type the integration process here, so I decide to attach the pdf
document here.

The attachment shows the whole process of solving the integral.

In the end, I want to give me special gratitude to haruspex and Ray Vickson.

--
Best regards
Jacky Wu

Your final answer is incorrect, as I have already indicated; you made some errors in your computation.

However, it is possible to give a corrected answer, and it is not very difficult to get. Below, I use ##x_1, x_2, x_3## instead of ##\xi_1, \xi_2, \xi_3## and I use ##c_1, c_2, c_3## instead of ##\eta_1, \eta_2, \eta_3##. I will get the marginal density of ##x_3## instead of ##x_1##, but by a simple re-labelling you can get the other two marginals as well. The density function is
P(x_1,x_2,x_3) = k \frac{\delta(1 - \sqrt{x_1^2 + x_2^2 + x_3^2})}{( 1 - c_1 x_1 <br /> - c_2 x_2 - c_3 x_3)^2},
where k is a constant which you give in the pdf file. Let's change to polar coordinates:
x_1 = r \sin(\theta) \cos(\phi)\\<br /> x_2 = r \sin(\theta) \sin(\phi)\\<br /> x_3 = r \cos(\theta).
When we fix x_3 the area element is ##dA = dx_1 dx_2 = R\, dR\, d\phi##, where ##R = r \sin(\theta)##, so ##dR = dr \sin(\theta)## (since, ultimately, we are fixing θ). Thus, ##dA = r \sin^2(\theta) dr \, d\phi##, so the marginal density ##f(x_3)## is given as
f = k \sin^2(\theta) \int_0^{2 \pi} <br /> \frac{1}{(1 - c_1 \sin(\theta) \cos(\phi) - c_2 \sin(\theta) \sin(\phi) - c_3 \cos(\theta))^2} \, d \phi,
because the r-integration is simply ##\int \delta(r-1) q(r,\phi)\, dr##. Note that since r = 1 we have ##\cos(\theta) = x_3## and ##\sin(\theta) = \sqrt{1-x_3^2}.## We may write
c_1 \sin(\theta) \cos(\phi) + c_2 \sin(\theta) \sin(\phi) = C \cos(\omega - \phi), where ##C = \sin(\theta) \sqrt{c_1^2 + c_2^2}## and ##\cos(\omega) = c_1 \sin(\theta)/C, \: \sin(\omega) = \sin(\theta) c_2/C.## Since we are integrating ##\phi## over an entire cycle, we can omit ##\omega## and write
f = k (1-x_3^2) \int_0^{2 \pi} \frac{1}{(1 - C \cos(\phi) -c_3 x_3)^2}\, d\phi<br /> = k (1-x_3^2) \text{sign}(x_3 - 1 -C)\frac{2(c_3 x_3 - 1)}{( 1 - 2 c_3 x_3 + c_3^2 x_3^2 - c_1^2 - c_2^2 - C^2)^{3/2}}.
Since ##x_3 \in (-1,1)## we have sign = -1, so finally we have
f(x_3) = \text{const.} \frac{(1 - c_3 x_3)(1 - x_3^2)}{( (1 - c_3 x_3)^2 - (c_1^2 + c_2^2)(1 - x_3^2))^{3/2}}, \: -1 \leq x_3 \leq 1.
Here, we assume that ##c_1^2 + c_2^2 + c_3^2 < 1## and also that the denominator function ## (1 - c_3 x_3)^2 - (c_1^2 + c_2^2)(1 - x_3^2)## does not vanish for ##x_3 \in [-1,1].## A sufficient condition for this is that
1 - c_1^2 - c_2^2 - c_3^2 &gt; 2 c_3. When the denominator function vanishes at some point in (-1,1) the integral is singular at some values of ##x_3##, and the computation breaks down.

Note that this formula gives ##f(x_3) \to 0## as ## x_3 \to \pm 1##, as it must be (since having x_3 = ± 1 gives an integration over a region of area = 0). The formula you gave in post #9 does not have this necessary property.
 
Last edited:
  • #24
Ray Vickson said:
Your final answer is incorrect, as I have already indicated; you made some errors in your computation.

However, it is possible to give a corrected answer, and it is not very difficult to get. Below, I use ##x_1, x_2, x_3## instead of ##\xi_1, \xi_2, \xi_3## and I use ##c_1, c_2, c_3## instead of ##\eta_1, \eta_2, \eta_3##. I will get the marginal density of ##x_3## instead of ##x_1##, but by a simple re-labelling you can get the other two marginals as well. The density function is
P(x_1,x_2,x_3) = k \frac{\delta(1 - \sqrt{x_1^2 + x_2^2 + x_3^2})}{( 1 - c_1 x_1 <br /> - c_2 x_2 - c_3 x_3)^2},
where k is a constant which you give in the pdf file. Let's change to polar coordinates:
x_1 = r \sin(\theta) \cos(\phi)\\<br /> x_2 = r \sin(\theta) \sin(\phi)\\<br /> x_3 = r \cos(\theta).
When we fix x_3 the area element is ##dA = dx_1 dx_2 = R\, dR\, d\phi##, where ##R = r \sin(\theta)##, so ##dR = dr \sin(\theta)## (since, ultimately, we are fixing θ). Thus, ##dA = r \sin^2(\theta) dr \, d\phi##, so the marginal density ##f(x_3)## is given as
f = k \sin^2(\theta) \int_0^{2 \pi} <br /> \frac{1}{(1 - c_1 \sin(\theta) \cos(\phi) - c_2 \sin(\theta) \sin(\phi) - c_3 \cos(\theta))^2} \, d \phi,
because the r-integration is simply ##\int \delta(r-1) q(r,\phi)\, dr##. Note that since r = 1 we have ##\cos(\theta) = x_3## and ##\sin(\theta) = \sqrt{1-x_3^2}.## We may write
c_1 \sin(\theta) \cos(\phi) + c_2 \sin(\theta) \sin(\phi) = C \cos(\omega - \phi), where ##C = \sin(\theta) \sqrt{c_1^2 + c_2^2}## and ##\cos(\omega) = c_1 \sin(\theta)/C, \: \sin(\omega) = \sin(\theta) c_2/C.## Since we are integrating ##\phi## over an entire cycle, we can omit ##\omega## and write
f = k (1-x_3^2) \int_0^{2 \pi} \frac{1}{(1 - C \cos(\phi) -c_3 x_3)^2}\, d\phi<br /> = k (1-x_3^2) \text{sign}(x_3 - 1 -C)\frac{2(c_3 x_3 - 1)}{( 1 - 2 c_3 x_3 + c_3^2 x_3^2 - c_1^2 - c_2^2 - C^2)^{3/2}}.
Since ##x_3 \in (-1,1)## we have sign = -1, so finally we have
f(x_3) = \text{const.} \frac{(1 - c_3 x_3)(1 - x_3^2)}{( (1 - c_3 x_3)^2 - (c_1^2 + c_2^2)(1 - x_3^2))^{3/2}}, \: -1 \leq x_3 \leq 1.
Here, we assume that ##c_1^2 + c_2^2 + c_3^2 < 1## and also that the denominator function ## (1 - c_3 x_3)^2 - (c_1^2 + c_2^2)(1 - x_3^2)## does not vanish for ##x_3 \in [-1,1].## A sufficient condition for this is that
1 - c_1^2 - c_2^2 - c_3^2 &gt; 2 c_3. When the denominator function vanishes at some point in (-1,1) the integral is singular at some values of ##x_3##, and the computation breaks down.

Note that this formula gives ##f(x_3) \to 0## as ## x_3 \to \pm 1##, as it must be (since having x_3 = ± 1 gives an integration over a region of area = 0). The formula you gave in post #9 does not have this necessary property.

Thanks for your reply.

Actually I don't know where the problem is?

But the result of f(\xi) appears in several academic papers.

I will check it later to find out which one suits better and try to find out the exact problem.
 
  • #25
Wu Xiaobin said:
Thank you so much if anyone can solve this integral to obtain its individual marginal PDF.

The joint probability density function shows as follows:
f(\xi_1,\xi_2)=\frac{1-\eta_1^2-\eta_2^2-\eta_3^2}{4\pi}[\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2-\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}+\frac{1}{(1-\eta_1\xi_1-\eta_2\xi_2+\eta_3\sqrt{1-\xi_1^2-\xi_2^2})^2}]
with the domain of integration 0\leq(\xi_1^2+\xi_2^2\leq1)

And I want to integrate the above joint probability density function to obtain f(\xi_1)

No fair! You posted incorrect, misleading information. You say you wanted to find the marginal density of ##x_1## from the bivariate density
f(x_1,x_2) = c \left[ \frac{1}{(1-c_1 x_1 - c_2 x_2 - c_3 \sqrt{1-x_1^2 - x_2^2})^2} +<br /> \frac{1}{(1-c_1 x_1 - c_2 x_2 + c_3 \sqrt{1-x_1^2 - x_2^2})^2} \right], \; x_1^2 + x_2^2 \leq 1,
but in fact, your bivariate density should be
f(x_1,x_2) = \frac{c}{\sqrt{1-x_1^2-x_2^2}} \left[ \frac{1}{(1-c_1 x_1 - c_2 x_2 - c_3 \sqrt{1-x_1^2 - x_2^2})^2} +<br /> \frac{1}{(1-c_1 x_1 - c_2 x_2 + c_3 \sqrt{1-x_1^2 - x_2^2})^2} \right], \; x_1^2 + x_2^2 \leq 1 (from your pdf file). This makes all the difference in the world! The first form leads to ##f(x_1) \to 0## as ##x_1 \to \pm 1##, while this does not happen for the second form!
 
  • #26
Ray Vickson said:
No fair! You posted incorrect, misleading information. You say you wanted to find the marginal density of ##x_1## from the bivariate density
f(x_1,x_2) = c \left[ \frac{1}{(1-c_1 x_1 - c_2 x_2 - c_3 \sqrt{1-x_1^2 - x_2^2})^2} +<br /> \frac{1}{(1-c_1 x_1 - c_2 x_2 + c_3 \sqrt{1-x_1^2 - x_2^2})^2} \right], \; x_1^2 + x_2^2 \leq 1,
but in fact, your bivariate density should be
f(x_1,x_2) = \frac{c}{\sqrt{1-x_1^2-x_2^2}} \left[ \frac{1}{(1-c_1 x_1 - c_2 x_2 - c_3 \sqrt{1-x_1^2 - x_2^2})^2} +<br /> \frac{1}{(1-c_1 x_1 - c_2 x_2 + c_3 \sqrt{1-x_1^2 - x_2^2})^2} \right], \; x_1^2 + x_2^2 \leq 1 (from your pdf file). This makes all the difference in the world! The first form leads to ##f(x_1) \to 0## as ##x_1 \to \pm 1##, while this does not happen for the second form!
Oh my god!

I feel terribly sorry for all of my friends. I regret for posting the wrong integral in the previous post. Especially for Ray Vickson. Thank you so much for your persistence.

Again please accept my sincere apology for giving the wrong equation.

--
Best regards
Jacky Wu
 

Similar threads

  • · Replies 7 ·
Replies
7
Views
6K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 105 ·
4
Replies
105
Views
10K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 20 ·
Replies
20
Views
5K
Replies
3
Views
2K
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
Replies
11
Views
3K