![]() Volume 9, Issue 4 Articles Tricks of the Trade In and Out Trott's Corner New Products New Publications Calendar News Bulletins New Resources Classifieds Download This Issue Editorial Policy Staff and Contributors Submissions Subscriptions Advertising Back Issues Contact Information |
Moment-Based Density Approximants
2. Approximants Based on Legendre PolynomialsA polynomial density approximation formula which applies to any continuous distribution having a compact support is obtained in this section. This approximant is derived from an analytical result stated in [10], which is couched in statistical nomenclature in this section. The density function of a continuous random variable
where
with
[13]. Legendre polynomials can also be obtained by means of a recurrence relationship, which is derived for instance in [9, 178]. Given the first
that is,
in Mathematica notation, where the pattern matching symbol
As explained in [14, 439], this polynomial turns out to be the least-squares approximating polynomial of degree We now turn our attention to the more general case of a continuous random variable
As pointed out in the Introduction, alternative methods are available for evaluating the moments of a distribution when the exact density is unknown. On mapping
we obtain the desired range for
that is,
or equivalently
Equation (6) can then be used to provide an approximant to the density function of
that is,
in Mathematica notation. On combining equations (9) and (13), one obtains the following compact representation of the density approximant:
Now, observing that
Thus, given It should be noted that the density approximants so obtained may be negative on certain subranges of the support of their distributions having low density. This will likely occur if an insufficient number of moments are being used. However, by mere inspection of the approximate density plot, we should be able to determine whether a higher degree polynomial ought to be used. Indeed, owing to the convergence of the approximant, the density function will converge everywhere to a nonnegative number as more moments are being used. If we wish to obtain a truly bona fide density function, we could always take a normalized function, In the following application, a polynomial approximation is obtained for the density of Example 1: Exact and Approximate Density Functions of VLet The closed-form representation of the density function of
where the functions The
whose evaluation can be handled by Mathematica. However, on noting that the density function of
Figure 1 shows the exact probability density function (PDF) of
Figure 1. Exact and approximate (dashed line) PDFs. [Pq or Pq1 in the Appendix]
Figure 2. Exact and approximate (dashed line) CDFs. [PQ in the Appendix] As Figure 3 indicates, the exact and approximate CDFs differ by less than 0.001 over the interval
Figure 3. The difference between the exact and approximate CDFs. [Qd in the Appendix] Example 2: Approximate Density of a Mixture of Beta Random VariablesConsider a mixture of two equally weighted beta distributions with parameters
Figure 4. Exact and approximate (dashed line) PDFs. [Pb in the Appendix] As specified in Section 4, approximants that are expressed in terms of Jacobi polynomials are ideally suited for approximating beta-type density functions. However, in the absence of prior knowledge about the shape of a density function, it is indicated to make use of approximants based on Legendre polynomials as they can theoretically accommodate any continuous distribution defined on a closed interval. It should be pointed out that if a density function turns out to be very irregular, a prohibitive number of moments might be required to approximate it satisfactorily. Thankfully, the majority of continuous distributions of interest are smooth and possess at most a few modes.
|
||||||||
About Mathematica | Download Mathematica Player © 2005 Wolfram Media, Inc. All rights reserved. |