1
$\begingroup$

Say we have three stochastic variables defined as follows:

rho = NormalDistribution[rhom,sigmar];
beta = NormalDistribution[betam,sigmab];
alpha = NormalDistribution[alpham,sigmaa];

I would like to compute the central moments of the following vector containing functions of such variables:

ml={{rho/(Sqrt[1+Tan[alpha]^2+Tan[beta]^2]) Tan[alpha]},
    {rho/(Sqrt[1+Tan[alpha]^2+Tan[beta]^2]) Tan[beta]},
    {rho/(Sqrt[1+Tan[alpha]^2+Tan[beta]^2])}};

How can this task be fulfilled taking advantage of the definition of such Distribution objects?

$\endgroup$
3
  • 2
    $\begingroup$ Before looking further, you have not specified whether or not the random variables are independent. You have also not stated which central moments you seek. $\endgroup$
    – wolfies
    Commented Sep 29, 2023 at 14:18
  • 1
    $\begingroup$ Mathematica codes sprinkled in these CV threads might give you some ideas: stats.stackexchange.com/q/144138/72352 and stats.stackexchange.com/q/144302/72352. $\endgroup$
    – corey979
    Commented Sep 29, 2023 at 16:05
  • $\begingroup$ Because rho is involved in all of the random variables as a multiplicative factor, if rho is independent of both alpha and beta, then it would be best to concentrate on dealing with the distributions of the parts that deal with alpha and beta. In other words this reduces the issue to dealing with just 2 random variables as adding an independent multiplicative random variable is easy to include. $\endgroup$
    – JimB
    Commented Sep 30, 2023 at 1:01

2 Answers 2

3
$\begingroup$

Is not likely that Mathematica will return an analytical expression for such a complicated distribution. The form should be as follows, with a simpler TransformedDistribution of rho+alpha+beta and assuming variables are independent.

Assuming[
    And[
        Element[alpha | alpham | beta | betam | rho | rhom, Reals],
        Element[sigmaa | sigmab | sigmar, PositiveReals]
    ],
    With[
    {
        dist=TransformedDistribution[
            rho+alpha+beta
            , {
                Distributed[rho, NormalDistribution[rhom, sigmar]],
                Distributed[beta, NormalDistribution[betam, sigmab]],
                Distributed[alpha, NormalDistribution[alpham, sigmaa]]
            }
    ]
    },
    Table[CentralMoment[dist,n],{n,4}]
    ]
]

For me, this has been running for way too long without an answer:

Assuming[
    And[
        Element[alpha | alpham | beta | betam | rho | rhom, Reals],
        Element[sigmaa | sigmab | sigmar, PositiveReals]
    ],
    With[
    {
        dist=TransformedDistribution[
            rho/(Sqrt[1+Tan[alpha]^2+Tan[beta]^2]) Tan[alpha]
            , {
                Distributed[rho, NormalDistribution[rhom, sigmar]],
                Distributed[beta, NormalDistribution[betam, sigmab]],
                Distributed[alpha, NormalDistribution[alpham, sigmaa]]
            }
    ]
    },
    Table[CentralMoment[dist,n],{n,4}]
    ]
]
$\endgroup$
3
$\begingroup$

This is an extended comment to echo @rhermans answer: I suspect the moments (and especially the pdf's) are unlikely to be found in a simple form even for a specified set of parameters.

Consider the following example (assuming that rho, beta, and alpha are all independent) for the first element in your vector:

n = 1000000;
SeedRandom[12345];
rho = RandomVariate[NormalDistribution[5, 1], n];
beta = RandomVariate[NormalDistribution[2, 3], n];
alpha = RandomVariate[NormalDistribution[-2, 1/2], n];
d1 = rho/(Sqrt[1 + Tan[alpha]^2 + Tan[beta]^2]) Tan[alpha];
Histogram[d1, "FreedmanDiaconis", "PDF"]

Histogram of samples from first element of desired vector of random variable

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.