2021

[1]Joanna Janczura

1]Faculty of Pure and Applied Mathematics, Wroclaw University of Science and
Technology, Wyb. Wyspiańskiego 27, Wrocław, 50-370, Poland

2]KGHM, M. Skłodowskiej-Curie 48, M. Skłodowskiej-Curie 48, 59-301, Poland

# On the distribution of the product of two continuous random variables with
an application to electricity market transactions. Finite and infinite-
variance case.

Julia Adamska<EMAIL_ADDRESS>Łukasz Bielak<EMAIL_ADDRESS><EMAIL_ADDRESS>Agnieszka Wyłomańska
<EMAIL_ADDRESS>[  [

###### Abstract

In this paper we study the distribution of a product of two continuous random
variables. We derive formulas for the probability density functions and
moments of the products of the Gaussian, log-normal, Student’s t and Pareto
random variables. In all cases we analyze separately independent as well as
correlated random variables. Based on the theoretical results we use the
general maximum likelihood approach for the estimation of the parameters of
the product random variables and apply the methodology for a real data case
study. We analyze a distribution of the transaction values, being a product of
prices and volumes, from a continuous trade on the German intraday electricity
market.

###### keywords:

product, Gaussian distribution, log-normal distribution, Pareto distribution,
Student’s t distribution, correlation coefficient, electricity market

###### pacs:

[

MSC Classification]60E05, 91B26, 62E15, 65C20, 33-02

##  1 Introduction

One of important problems in statistics and applied mathematics is the
recognition of distributions corresponding to various functions of two (or
even more) random variables. In the literature different transformations of
two random variables, such as a sum, product, ratio, etc., are considered. In
this paper we focus on the product function, i.e we analyze the random
variable defined as

$Z=XY,$ (1)

where $X$ and $Y$, called marginal random variables, have continuous
distributions.

The considered problem is not new and there are various examples of random
variables for which the product is analyzed in theory and in practice.
Particular emphasis is placed on the product of two random variables that come
from the same class of distributions, see eg. logistic ; pearson ; eliptically
; trapezoidal . In this case one can find interesting approaches used in the
analysis of the distribution and probabilistic properties of the product
random variable. The special attention is paid to the case when two considered
random variables are Gaussian or Student’s t distributed, see e.g.
Ahsanullah_2014 ; student_t ; gauss2 ; gauss1 ; student_statistical . The
other interesting cases one can find also in exponential , where exponentially
distributed random variables are considered or in dirichlet , where Dirichlet
distributed random variables are examined. For other references, see also beta
; beta2 ; pareto2 ; beta_statistical . Different classes of distributions are
also considered in the literature and the product of such random variables is
analyzed, see eg. normal_laplace ; gauss_laplace2 ; gama_weibul ; gama_beta ;
pareto_gama ; beta_statistical  and references therein.

Beyond theoretical considerations, the random variables that arise as a
product (or other functions) of two variables have found various interesting
applications including finance, risk management, economy, but also physical
sciences, reliability theory, hydrology, and many others, see eg. appl1 ;
appl2 ; appl3 ; appl4 ; appl5 ; appl6 ; appl7 ; appl8 ; appl10 .

There are known general formulas that can be useful when one considers the
random variable defined in Eq. (1). For instance, in the general case the
probability density function (PDF) of $Z$ is given by gauss1 ; rohatgi2015

$f_{Z}(z)=\int_{-\infty}^{\infty}\frac{1}{\mid
x\mid}f_{X,Y}\left(x,\frac{z}{x}\right)dx,$ (2)

where $f_{X,Y}(x,y)$, $x,y\in\mathbb{R}$ is a two-dimensional PDF of the
vector $(X,Y)$.

In this paper we separately study examples of finite- and infinite-variance
distributions of the marginal random variables. The sample distributions of
the first class considered in this paper are the Gaussian and log-normal,
while of the second class - the Student’s t Ahsanullah_2014  and Pareto
distributions Mardia_1962 . We consider two cases. In the first one the
marginal random variables come from the same class of distributions, while in
the second one - they are representatives of different classes.

Obviously, the general properties of the product simplify when the marginal
random variables are independent. In that case, the corresponding bi-
dimensional random vector has the PDF that is a product of the marginal
densities, i.e. we have

$f_{Z}(z)=\int_{-\infty}^{\infty}\frac{1}{\mid
x\mid}f_{X}(x)f_{Y}\left(\frac{z}{x}\right)dx.$ (3)

where $f_{X}(x)$ and $f_{Y}(y)$ are the PDF’s of the marginal distributions
corresponding to $X$ and $Y$, respectively.

The situation is much more complicated when the marginal random variables are
statistically dependent. In that case the simplest way to express the
dependence between them is the correlation coefficient. However, the
correlation coefficient equal to zero does not always correspond to the case
when the marginal random variables are statistically independent. From the
distributions considered in this paper, this is the case for the Student’s t
and Pareto ones. Moreover, for the infinite-variance random variables, the
correlation coefficient is infinite as well. Thus, various other approaches
might be also considered. One of the ideas utilizes copula as the dependency
measure appl5 ; copula2 ; copula3 . Other dependency measures, adequate for
infinite-variance random variables are presented e.g. in
wylomanska2015codifference ; slkezak2019codifference ; stable ; nowicka1 .

The main goal of the paper is to determine probability density functions of
the product random variable for the considered distributions and examine, how
the probabilistic properties of the marginal random variables influence the
distributional properties of the final product.

The second goal of the paper is the analysis of the distribution of the
product random variable when the marginal random variables come from different
classes of distributions. The main attention is paid to the analysis on how
the parameter responsible for distribution tail influences the PDF of the
product random variable.

The obtained theoretical properties are used for the estimation of the product
random variable parameters. We use a general idea based on the maximum
likelihood algorithm. With the Monte Carlo simulations we confirm the
effectiveness of the procedure. Finally, the methodology is applied to real
data from the energy market. We analyze a distribution of the transaction
values, being a product of prices and volumes, from a continuous trade on the
German intraday electricity market. We show that using the derived product
distribution a good fit to the transaction values data can be obtained, being
at the same time consistent with the corresponding prices and volumes
distributions.

The rest of the paper is organized as follows: First, we discuss the
probabilistic properties of a random variable that arises as a product of
random variables coming from two exemplary finite-variance distributions.
Next, in Section 3 we provide similar considerations for the exemplary random
variables from infinite-variance class of distributions. In Section 4 we
discuss the case when the marginal random variables come from different
classes of distributions. The probabilistic properties of the product random
variable are calculated and the influence of the parameters of the marginal
distributions is discussed. The next part is devoted to the practical aspects
of the obtained results. Namely, in Section 5 we propose a general methodology
for the estimation of the parameters for the product random variable, while in
Section 6 we apply the methodology to a real-data case. We analyze the
transactions data from the German electricity market settled on the EPEX
energy exchange. Last section concludes the paper and presents other possible
applications of the proposed methodology.

##  2 Product of finite-variance distributed random variables

In this section we consider exemplary distributions of $X$ and $Y$ that belong
to the finite-variance class, namely the Gaussian and log-normal ones. We
recall the known results for the product of two-dimensional Gaussian
distribution and derive the corresponding formulas for the log-normal one. It
is worth mentioning, that for these distributions the independence between $X$
and $Y$ is equivalent to the zero valued correlation coefficient and in that
case the PDF of the two-dimensional vector $(X,Y)$ is given by Eq. (3).

###  2.1 Gaussian distribution

The two-dimensional Gaussian distributed random random vector $(X,Y)$ has the
following PDF Roussas_2015

$f_{X,Y}(x,y)=\frac{\exp\Bigg{\\{}-\frac{1}{2(1-\rho^{2})}\left[\frac{(x-\mu_{X})^{2}}{\sigma_{X}^{2}}-2\rho\left(\frac{x-\mu_{X}}{\sigma_{X}}\right)\left(\frac{y-\mu_{Y}}{\sigma_{Y}}\right)+\frac{(y-\mu_{Y})^{2}}{\sigma_{Y}^{2}}\right]\Bigg{\\}}}{2\pi\sigma_{X}\sigma_{Y}\sqrt{1-\rho^{2}}},$
(4)

where $x,y\in\mathbb{R}$, $\rho\in(-1,1)$ is the correlation coefficient
between random variables $X$ and $Y$; $\mu_{X},\mu_{Y}\in\mathbb{R}$ are the
corresponding expected values, while $\sigma_{X},\sigma_{Y}>0$ are the
corresponding standard deviations. The cases $\rho=1$ or $\rho=-1$ are not
considered in this paper. However, they correspond to the situation when
$Y=aX$, with $a\in\mathbb{R}$. As a consequence, the product random variable
$Z$ has a chi-square distribution with one degree of freedom. It is easy to
see that, when $\rho=0$, the PDF of the random vector $(X,Y)$ is just a
product of the PDFs of the Gaussian distributed random variables.

For simplicity we assume that $\mu_{X}=\mu_{Y}=0$. In that case the PDF of the
random variable $Z$ defined in (1) is given by Gaunt_2018

$f_{Z}(z)=\frac{1}{\pi\sigma_{X}\sigma_{Y}\sqrt{1-\rho^{2}}}\exp\Bigg{\\{}\frac{\rho
z}{\sigma_{X}\sigma_{Y}(1-\rho^{2})}\Bigg{\\}}K_{0}\left(\frac{\mid
z\mid}{\sigma_{X}\sigma_{Y}(1-\rho^{2})}\right),$ (5)

where $z\in\mathbb{R}$, $K_{0}(\cdot)$ is the Bessel function of the second
kind with a purely imaginary argument of zero order. Recall that the family of
the modified Bessel functions of the second kind for order $v$ is given by
$K_{v}(x)=\int_{0}^{\infty}\exp\\{-x\cosh(t)\\}\cosh(vt)dt$. The formula for
$f_{Z}(\cdot)$ in the general case with $\mu_{X}=\mu_{Y}\in\mathbb{R}$ can be
found in general_normal .

One can show that the PDF given in Eq. (5) corresponds to the variance-gamma
distribution PDF:
$VG(1,\rho\sigma_{x}\sigma_{y},\sigma_{x}\sigma_{y}\sqrt{1-\rho^{2}},0)$. The
expected value and the variance of $Z$ in the general case are given by
Craig_1936

$\displaystyle\mathbb{E}(Z)$
$\displaystyle=\mu_{X}\mu_{Y}+\rho\sigma_{X}\sigma_{Y},$ (6) $\displaystyle
Var(Z)$
$\displaystyle=\sigma_{X}^{2}\mu_{Y}^{2}+\sigma_{Y}^{2}\mu_{X}^{2}+\sigma_{X}^{2}\sigma_{Y}^{2}+2\rho\mu_{X}\mu_{Y}\sigma_{X}\sigma_{Y}+\rho^{2}\sigma_{X}^{2}\sigma_{Y}^{2}.$
(7)

It is interesting to note that, for correlated marginal variables the
individual scale parameters, $\sigma_{X},\sigma_{Y}$ influence also the
expected value of the product, $\mathbb{E}(Z)$, and for central marginal
distributions we have $\mathbb{E}(Z)\neq 0$. On the other hand, if $\rho=0$,
then the product expectation is just the product of the individual means,
$\mu_{X},\mu_{Y}$. The variance of the product is equal to the product of
individual variances only if $\mu_{X}=\mu_{Y}=0$ and the marginal variables
are uncorrelated. Otherwise, it is a function of all individual parameters.

####  2.1.1 Log-normal distribution

The two-dimensional log-normally distributed random vector $(X,Y)$ with
parameters $\mu_{X},\mu_{Y}\in\mathbb{R}$, $\sigma_{X},\sigma_{Y}>0$ and
$\rho\in(-1,1)$ is defined in the following way log_multi

$\displaystyle(X,Y)=\exp\\{(N_{1},N_{2})\\},$ (8)

where $(N_{1},N_{2})$ is the Gaussian random vector defined by the PDF in Eq.
(4) with the parameters $\mu_{X},\mu_{Y},\sigma_{X},\sigma_{Y}$ and $\rho$.
Thus, the marginal random variables $X$ and $Y$ have the representations

$\displaystyle X=\exp\\{N_{1}\\},~{}Y=\exp\\{N_{2}\\}$ (9)

and in the general case the $\rho$ parameter is the correlation between
$N_{1}$ and $N_{2}$. This influences also the correlation between $X$ and $Y$.
Indeed, one can easily show that the covariance between $X$ and $Y$ is as
follows

$\displaystyle\text{cov}(X,Y)=\exp\left\\{\mu_{X}+\mu_{Y}+\frac{1}{2}(\sigma_{X}^{2}+\sigma_{Y}^{2})\right\\}\Bigg{[}\exp\left\\{\rho\sigma_{X}\sigma_{Y}\right\\}-1\Bigg{]}.$
(10)

The PDF of $(X,Y)$ is given by Yerel_BVLN

$f_{X,Y}(x,y)=\frac{\exp\Bigg{\\{}-\frac{\frac{(\log(x)-\mu_{X})^{2}}{\sigma_{X}^{2}}-2\rho\frac{(\log(x)-\mu_{X})(\log(y)-\mu_{Y})}{\sigma_{X}\sigma_{Y}}+\frac{(\log(y)-\mu_{Y})^{2}}{\sigma_{Y}^{2}}}{2(1-\rho^{2})}\Bigg{\\}}}{2\pi
xy\sigma_{X}\sigma_{Y}\sqrt{1-\rho^{2}}},$ (11)

where $x,y>0$. If $\rho=0$, the marginal variables $X$ and $Y$ are independent
and the PDF given in (11) is a product of PDFs of one-dimensional random
variables with the log-normal distribution. The cases $\rho=1$ and $\rho=-1$
are not considered in this paper. However, one can notice that in these cases
the product random variable $Z$ has still the log-normal distribution.

One can show that the random variable $Z$ defined in Eq. (1) in the considered
case has also one-dimensional log-normal distribution. Indeed, from Eq. (9)
one has

$Z=XY=\exp\\{N_{1}+N_{2}\\}.$

Since $N_{1}$ and $N_{2}$ are jointly Gaussian, the random variable
$N_{1}+N_{2}$ still has the Gaussian distribution with the expected value
$\mu_{X}+\mu_{Y}$ and the variance
$\sigma_{X}^{2}+\sigma_{Y}^{2}+2\rho\sigma_{X}\sigma_{Y}$. Thus, the PDF of
$Z$ has the following form

$\displaystyle
f_{Z}(z)=\frac{1}{\sqrt{2\pi(\sigma_{X}^{2}+\sigma_{Y}^{2}+2\rho\sigma_{X}\sigma_{Y})}z}\exp\left\\{-\frac{1}{2}\frac{(\log(z)-\mu_{X}-\mu_{Y})^{2}}{\sigma_{X}^{2}+\sigma_{Y}^{2}+2\rho\sigma_{X}\sigma_{Y}}\right\\}$
(12)

for $z>0$. The resulting product distribution is still log-normal with the
following parameters: $\mu_{Z}=\mu_{X}+\mu_{Y}$ and
$\sigma^{2}_{Z}=\sigma_{X}^{2}+\sigma_{Y}^{2}+2\rho\sigma_{X}\sigma_{Y}$.
Hence, the $\rho$ coefficient influences the scale parameter of the resulting
distribution.

##  3 Product of infinite-variance distributed random variables

In this section, we consider exemplary distributions of $X$ and $Y$ that
belong to the infinite-variance class of distributions. The considered cases
are the Student’s t and Pareto. In contrast to the finite-variance
distributions considered in the previous section, the zero correlation
coefficient does not correspond to the case when the marginal random variables
are statistically independent.

###  3.1 Student’s t distribution

A common method of construction of a two-dimensional Student’s t distributed
random vector $(X,Y)$ is based on the following observation. Let us assume
that $(N_{1},N_{2})$ is the two-dimensional Gaussian vector defined by the PDF
in Eq. (4) with the parameters $\mu_{X}=\mu_{Y}=0$, $\sigma_{X}=\sigma_{Y}=1$
and $\rho\in(-1,1)$, and $\chi^{2}$ is the one-dimensional random variable
with chi-square distribution with $n>0$ degrees of freedom. Moreover, assume
that $(N_{1},N_{2})$ and $\chi^{2}$ are independent. Then the random vector
defined as

$\displaystyle(X,Y)=\frac{(N_{1},N_{2})}{\sqrt{\chi^{2}/n}}$ (13)

has a two-dimensional Student’s t distribution with $n$ degrees of freedom and
its PDF is given by Lai_2009

$f_{X,Y}(x,y)=\frac{1}{2\pi\sqrt{1-\rho^{2}}}\left[1+\frac{x^{2}-2\rho
xy+y^{2}}{n(1-\rho^{2})}\right]^{-\frac{n+2}{2}},~{}~{}x,y\in\mathbb{R}.$ (14)

The marginal random variable $X$ (and $Y$) has the one-dimensional Student’s t
distribution defined by the PDF given by student_baza

$\displaystyle
f_{X}(x)=\frac{\Gamma((n+1)/2)}{\sqrt{n\pi}\Gamma(n/2)}\left(1+\frac{x^{2}}{n}\right)^{-(n+1)/2},~{}x\in\mathbb{R},$
(15)

where $\Gamma(\cdot)$ is the gamma function, i.e.
$\Gamma(\alpha)=\int_{0}^{\infty}t^{\alpha-1}e^{-t}dt$ for $\alpha$ such that
$\text{Re}(\alpha)>0$. Note that the number of degrees of freedom, $n$, is
equal for both marginal variables. For $n>2$ the random variables $X$ and $Y$
described by the PDF in (14) have the following covariance

$\displaystyle\text{cov}(X,Y)=\frac{n}{n-2}\rho.$ (16)

One can see that, although the zero correlation coefficient corresponds to
$\text{cov}(X,Y)=0$, it is not equivalent to the independence of the random
variables $X$ and $Y$, since in that case the PDF of a random vector $(X,Y)$
(see Eq. (14)) is not a product of the PDFs of the marginal distributions (see
Eq. 15). Similarly, as for the previously considered examples, the cases
$\rho=1$ and $\rho=-1$ are not analyzed in this paper.

In the case when the random vector $(X,Y)$ is described by the PDF given in
Eq. (14), then using formula (2) one obtains

$\displaystyle
f_{Z}(z)=\frac{1}{2\pi\sqrt{1-\rho^{2}}}\int_{-\infty}^{\infty}\frac{1}{\mid
x\mid}\left[1+\frac{x^{2}-2\rho
z+\frac{z^{2}}{x^{2}}}{n(1-\rho^{2})}\right]^{-\frac{n+2}{2}}dx,~{}x\in\mathbb{R}.$
(17)

The integral in Eq. (17) has no closed form and can be expressed by means of
the Appel hypergeometric special function. However, one can obtain its value
with numerical calculations.

If the random variables $X$ and $Y$ are independent and are described by the
Student’s t distributions of PDFs given in Eq. (15) with degrees of freedom
$n_{X}>0$ and $n_{Y}>0$ for X and Y distributions, respectively, then the PDF
of the vector $(X,Y)$ is given by a product of marginal densities of $X$ and
$Y$. Thus, the product random variable $Z$ has the following PDF for
$z\in\mathbb{R}$ Ahsanullah_2014

$f_{Z}(z)=\frac{2\Gamma{\left(\frac{n_{X}+1}{2}\right)}\Gamma{\left(\frac{n_{Y}+1}{2}\right)}}{\sqrt{n_{X}n_{Y}}\pi\Gamma{\left(\frac{n_{X}}{2}\right)}\Gamma{\left(\frac{n_{Y}}{2}\right)}}\int_{0}^{\infty}\frac{1}{x}\left(1+\frac{x^{2}}{n_{X}}\right)^{-\frac{n_{X}+1}{2}}\left(1+\frac{z^{2}}{x^{2}n_{Y}}\right)^{-\frac{n_{Y}+1}{2}}dx.$
(18)

Similarly as in the previous case, the above integral can only be calculated
numerically, as it has no closed form representation.

When one considers the random vector of the two-dimensional Student’s t
distribution defined by the PDF in Eq. (14), then the expectation (when $n>1$)
and the variance (when $n>2$) of the random variable $Z$ can be calculated
based on its PDF (see Eq. (17)). In this case, there are no closed forms for
the mentioned statistics. However, when $X$ and $Y$ are independent random
variables, then the expected value (if $n_{X},n_{y}>1$) and the variance (if
$n_{X},n_{Y}>2$) of the random variable $Z$ are given by Ahsanullah_2014

$\displaystyle\mathbb{E}(Z)=0,~{}~{}Var(Z)=\frac{n_{X}n_{Y}}{(n_{X}-2)(n_{Y}-2)}.$
(19)

The variance of the product of independent marginal variables is just a
product of the individual variances. Moreover, it tends to the variance of one
of the variables if the number of degrees of freedom of the second variable,
$n_{X}$ or $n_{Y}$, goes to infinity. If both parameters,
$n_{X},n_{Y}\rightarrow\infty$, then the variance of the product decreases to
1.

In Fig. 1 we demonstrate the PDF and the distribution tails (1-cumulative
distribution functions, 1-CDFs) of the random variable $Z$ that is a product
of marginal random variables from the two-dimensional Student’s t distribution
described by the PDF (14) for different values of the $\rho$ parameter. The
resulting PDF is symmetric only if $\rho=0$. Otherwise, it is right-skewed for
$\rho>0$ and left-skewed for $\rho<0$. The distribution tails are clearly
heavier than in the Gaussian case. For the comparison, we also show the plots
for the corresponding product of independent Student’s t marginal variables,
i.e., with PDF given by Eq. (18). The resulting distribution is again
symmetric, however, its tail is lighter than in the corresponding case of
dependent marginal variables.

Figure 1:  Distribution of the product of the marginal random variables from
the two-dimensional Student’s t distribution with $n=5$ and different values
of the $\rho$ parameter. Left panel: the PDF of the random variable $Z$. Right
panel: the distribution tail for the random variable $Z$ (in log-log scale).
The dotted line corresponds to the case when $X$ and $Y$ random variables are
independent and $n_{X}=n_{Y}=5$. The colors of the solid and dotted lines
correspond to the same $\rho$ parameter.

###  3.2 Pareto distribution

The two-dimensional Pareto distributed random vector $(X,Y)$ with parameters
$a,\theta_{X},\theta_{Y}>0$ has the following PDF Mardia_1962

$f_{X,Y}(x,y)=\frac{a(a+1)(\theta_{X}\theta_{Y})^{a+1}}{(x\theta_{Y}+y\theta_{X}-\theta_{X}\theta_{Y})^{a+2}},~{}x>\theta_{X},~{}y>\theta_{Y}.$
(20)

The above parametrization corresponds to the Pareto distribution of the first
kind paret . The $a$ parameter is responsible for the behavior of the
distribution tail. The marginal distributions of $X$ and $Y$ are given by

$\displaystyle
f_{X}(x)=\frac{a\theta_{X}^{a}}{x^{a+1}},~{}~{}x>\theta_{X},~{}~{}~{}~{}f_{Y}(y)=\frac{a\theta_{Y}^{a}}{y^{a+1}},~{}~{}y>\theta_{Y}.$
(21)

Note that the shape parameter $a$ is the same for both marginal distributions.
For $a>2$, the random variables $X$ and $Y$ described by the PDF (20) are
positively correlated. The covariance and correlation are given by,
respectively

$\displaystyle\text{cov}(X,Y)=\frac{\theta_{X}\theta_{Y}}{(a-1)^{2}(a-2)^{2}},~{}\text{corr}(X,Y)=\frac{1}{a}.$
(22)

It is interesting to note that here the correlation between the marginal
variables is governed by the shape parameter $a$. As a consequence, with such
parametrization, $X$ and $Y$ are always positively correlated.

When the random vector $(X,Y)$ is described by the PDF given in Eq. (20) using
formula (2) one obtains

$f_{Z}(z)=(a+1)a(\theta_{X}\theta_{Y})^{a+1}\int\limits_{\theta_{X}}^{\frac{z}{\theta_{Y}}}\frac{1}{x}(\theta_{Y}x+\theta_{X}\frac{z}{x}-\theta_{X}\theta_{Y})^{-a-2}dx,~{}~{}z>\theta_{X}\theta_{Y}.$
(23)

The integral in Eq. (23) has no closed form and can be expressed by means of
the Appel hypergeometric special function. However, one can obtain its value
with numerical calculations.

As one can see, the two-dimensional Pareto distribution defined by the PDF in
Eq. (20) does not cover the case with uncorrelated marginal random variables.
In the case when $X$ and $Y$ are independent and are described by the Pareto
distributions of the PDFs given in (21) with $a_{X},\theta_{X}>0$ and
$a_{Y},\theta_{Y}>0$, respectively, then the PDF of the vector $(X,Y)$ is
given by the product of the marginal PDFs, $f_{X}(x)$ and $f_{Y}(y)$.

######  Lemma 1.

Assume that the independent random variables $X$ and $Y$ have Pareto
distribution with parameters $a_{X},\theta_{X}$ and $a_{Y},\theta_{Y}$,
respectively. Then, for $a_{X}\neq a_{Y}$, the random variable $Z$ defined in
(1) has the following PDF

$f_{Z}(z)=a_{X}a_{Y}\left(\frac{z^{-a_{X}-1}(\theta_{X}\theta_{Y})^{a_{X}}}{a_{Y}-a_{X}}+\frac{z^{-a_{Y}-1}(\theta_{X}\theta_{Y})^{a_{Y}}}{a_{X}-a_{Y}}\right),~{}~{}z>\theta_{X}\theta_{Y}.$
(24)

When $a_{X}=a_{Y}=a$ the PDF of $Z$ has the following form

$\displaystyle
f_{Z}(z)=a^{2}(\theta_{X}\theta_{Y})z^{-a-1}\log\left(\frac{z}{\theta_{X}\theta_{Y}}\right),~{}~{}z>\theta_{X}\theta_{Y}.$
(25)

Proof: The proof comes directly from formula (3) and the fact that the PDF of
the random vector $(X,Y)$ is given by the product of marginal PDFs of $X$ and
$Y$ for $a_{X}\neq a_{Y}$ and $a_{X}=a_{Y}=a$. $\Box$.

When one considers a random vector of the two-dimensional Pareto distribution
defined by the PDF in Eq. (20), then there are no closed forms for the
expectation (when $a>1$) and the variance (when $a>2$) of the random variable
$Z$. However, when $X$ and $Y$ are independent random variables, then the
expected value and the variance of the random variable $Z$ are given by
Mardia_1962

$\displaystyle\mathbb{E}(Z)$
$\displaystyle=\frac{\theta_{X}\theta_{Y}a_{X}a_{Y}}{(a_{X}-1)(a_{Y}-1)},~{}~{}a_{X},a_{Y}>1,$
(26) $\displaystyle Var(Z)$
$\displaystyle=\theta_{X}^{2}\theta_{Y}^{2}a_{X}a_{Y}\left[\frac{(a_{X}-1)^{2}+(a_{Y}-1)^{2}-1}{(a_{X}-2)(a_{Y}-2)(a_{X}-1)^{2}(a_{Y}-1)^{2}}\right],~{}~{}a_{X},a_{Y}>2.$
(27)

In Fig. 2 we plot the PDF and the corresponding distribution tail of the
random variable $Z$ that is a product of marginal random variables from the
two-dimensional Pareto distribution described by the PDF (20) for different
values of the $a$ parameter. Recall that the correlation (if exists) is
directly related to the shape parameter $a$, i.e.
$\text{corr}(X,Y)=\frac{1}{a}$. So it is influenced by the distribution tails.
With larger $a$ (lower $\text{corr}(X,Y)$) the probability of extreme
observations becomes lower. In all cases, the distribution tails behave like a
power function with a clear linear shape in the double logarithmic scale. For
comparison, we also show the plots for the corresponding product of
independent Pareto marginal variables. In this case, the probabilities of
extreme observations are lower than for the corresponding dependent Pareto
distribution, but the power tail behavior is preserved.

Figure 2: Distribution of the product of marginal random variables from the
two-dimensional Pareto distribution with $\theta_{X}=\theta_{Y}=1$ and
different values of the $a$ parameter. Left panel: the PDF of the random
variable $Z$. Right panel: the distribution tail for the random variable $Z$
(in log-log scale). The dotted lines correspond to the case when $X$ and $Y$
are independent and $a_{X}=a_{Y}=a$, $\theta_{X}=\theta_{Y}=1$. The colors of
the solid and dotted lines correspond to the same $a$ parameter.

##  4 Product of finite- and infinite-variance distributed random variables

The distribution of the random variable that arises as a product of two other
random variables belonging to different families of distributions is of
considerable importance and current interest in various applications. In this
section, we examine the case when one of the marginal random variables is
finite-variance distributed, while the second one belongs to the infinite-
variance class. The product random variable shares some properties of both
marginal variables, but on the other hand it exhibits additional interesting
features. In this section, we assume that the marginal random variables are
independent.

###  4.1 Gaussian and Student’s t distributions

We assume that the one-dimensional random variable $X$ has the Gaussian
distribution with parameters $\mu_{X}\in\mathbb{R}$ and $\sigma_{X}>0$, while
the one-dimensional random variable $Y$ has the Student’s t distribution with
the PDF given in Eq. (15) with $n_{Y}>0$. We assume that $X$ and $Y$ are
independent, thus the PDF of the random vector $(X,Y)$ is just the product of
the corresponding marginal PDFs of $X$ and $Y$. Using Eq. (3) one obtains the
PDF of the random variable $Z$

$\displaystyle f_{Z}(z)$ $\displaystyle=$
$\displaystyle\int_{-\infty}^{\infty}\frac{1}{\mid
x\mid}f_{X,Y}\left(x,\frac{z}{x}\right)dx$ $\displaystyle=$
$\displaystyle\frac{\Gamma{\left(\frac{n_{Y}+1}{2}\right)}}{\pi\sigma_{X}\sqrt{2n_{Y}}\Gamma{\left(\frac{n_{Y}}{2}\right)}}\int_{-\infty}^{\infty}\frac{1}{\mid
x\mid}\exp\Bigg{\\{}-\frac{(x-\mu_{X})^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}\left(1+\frac{z^{2}}{n_{Y}x^{2}}\right)^{-\frac{n_{Y}+1}{2}}dx$
$\displaystyle=$
$\displaystyle\frac{2\Gamma{\left(\frac{n_{Y}+1}{2}\right)}}{\pi\sigma_{X}\sqrt{2n_{Y}}\Gamma{\left(\frac{n_{Y}}{2}\right)}}\int_{0}^{\infty}\frac{1}{x}\exp\Bigg{\\{}-\frac{(x-\mu_{X})^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}\left(1+\frac{z^{2}}{n_{Y}x^{2}}\right)^{-\frac{n_{Y}+1}{2}}dx.$

The PDF of $Z$ has no closed form representation and its calculation requires
numerical computation of the integral in Eq. (4.1). Using the fact that for
independent random variables the expected value of the product is the product
of expected values, one can easily show that

$\mathbb{E}(Z)=0,~{}~{}Var(Z)=\frac{n_{Y}}{n_{Y}-2}\sigma_{X}^{2},$ (29)

when $n_{Y}>2$. The expectation and the variance of the product are simply the
products of the corresponding moments of the marginal variables. Note that the
variance decreases to $\sigma_{X}^{2}$ with $n_{Y}\rightarrow\infty$.

In Fig. 3 we plot the PDF and the corresponding distribution tail of the
random variable $Z$ that is a product of two independent random variables from
the standard Gaussian (i.e. $N(0,1)$) and Student’s t distributions for
different values of the $n_{Y}$ parameter. The resulting distribution is
symmetric around zero. The shape of its tail is clearly dependent on the value
of the $n_{Y}$ parameter. For larger values of $n_{Y}$ the tails are close to
the Gaussian ones, while for lower $n_{Y}$ they become much heavier,
resembling rather the Student’s t tails. These three distributions, namely,
the Gaussian, Student’s t and their product, are compared in Fig. 4. One can
see that the product has a lighter tail than the Student’s t distributed
random variable but a heavier tail than the Gaussian one.

Figure 3: Distribution of the product of two independent random variables from
the Gaussian and Student’s t distribution with $\mu_{X}=0$ and $\sigma_{X}=1$
and different values of $n_{Y}$ parameter. Left panel: the PDF of the random
variable $Z$. Right panel: the distribution tail for the random variable $Z$
(in log-log scale). Figure 4: Left panel: the PDF of the random variables $X$
(Gaussian), $Y$ (Student’s t) and $Z$. Right panel: the distribution tail’s
for $X$, $Y$ and $Z$. The parameters are equal to: $\mu_{X}=0$ and
$\sigma_{X}=1$ and $n_{Y}=0.5$.

###  4.2 Gaussian and Pareto distributions

Assume that $X$ is a Gaussian distributed random variable with parameters
$\mu_{X}=0$ and $\sigma_{X}>0$ and $Y$ is a Pareto distributed random variable
with parameters $a_{Y}>0$ and $\theta_{Y}>0$. Moreover, we assume that $X$ and
$Y$ are independent.

######  Lemma 2.

The random variable $Z$ defined as a product of $X$ and $Y$ has the following
PDF

$\displaystyle
f_{Z}(z)=\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}\mid
z\mid^{a_{Y}+1}}2^{(a_{Y}-1)/2}\gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma^{2}\theta_{Y}^{2}}\right),~{}~{}z\in\mathbb{R},$
(30)

where $\Gamma(\cdot)$ is the Gamma function and $\gamma(\cdot,\cdot)$ is the
upper incomplete Gamma function defined as
$\gamma(\alpha,x)=\int_{0}^{x}t^{\alpha-1}\exp\\{-t\\}dt$.

The proof of this lemma is given in Appendix A.

Using the fact that $\gamma(a,x)\rightarrow\Gamma(a)$ when
$x\rightarrow\infty$, for $z\rightarrow\infty$ we have

$\displaystyle
f_{Z}(z)\sim\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}\mid
z\mid^{a_{Y}+1}}2^{(a_{Y}-1)/2}\Gamma\left(\frac{a_{y}+1}{2}\right).$ (31)

This indicates that the PDF of $Z$ has power-law behavior and thus in the
considered case the Pareto distribution dominates the tail behavior.

The expected value of $Z$ in the considered case, when $a_{Y}>1$, is equal to
zero and the variance of $Z$, if $a_{Y}>2$ is given by

$Var(Z)=\frac{(\theta_{Y}\sigma_{X})^{2}a_{Y}}{(a_{Y}-2)}.$ (32)

The variance decreases to the product of the marginal variables scale
parameters squares, $(\theta_{Y}\sigma_{X})^{2}$, as the Pareto shape
parameter $a_{Y}\rightarrow\infty$.

In Fig. 5 we plot the PDF and the corresponding distribution tail of the
random variable $Z$ that is a product of two independent random variables from
the Gaussian and Pareto distributions for different values of $a_{Y}$
parameter. Moreover in Fig. 6 we demonstrate the comparison of the PDFs and
distribution tails of $X$ and $Y$, and the corresponding random variable $Z$
for selected values of the parameters. One can see that the product has a
lighter tail than the Pareto distributed random variable but a heavier tail
than the Gaussian one. However, the power-law behavior, which corresponds to
Eq. (31), can be easily observed.

Figure 5: Distribution of the product of two independent random variables from
the Gaussian and Pareto distribution with $\mu_{X}=0$ and
$\sigma_{X}=\theta_{Y}=1$ and different values of the $a_{Y}$ parameter. Left
panel: the PDF of the random variable $Z$. Right panel: the distribution tail
for the random variable $Z$ (in log-log scale). Figure 6: Left panel: the PDF
of the random variables $X$ (Gaussian), $Y$ (Pareto) and $Z$. Right panel: the
distribution tails. The parameters are: $\mu_{X}=0$, $\sigma_{X}=\theta_{Y}=1$
and $a_{Y}=0.5$.

###  4.3 Log-normal and Student’s t distributions

In this section, we assume that the one-dimensional random variable $X$ has
the log-normal distribution with parameters $\mu_{X}\in\mathbb{R}$ and
$\sigma_{X}>0$, while the one-dimensional random variable $Y$ has the
Student’s t distribution with the PDF given in Eq. (15) with $n_{Y}>0$. We
assume that $X$ and $Y$ are independent. Using Eq. (3) one obtains that the
PDF of the random variable $Z$ is given by

$\displaystyle f_{Z}(z)$
$\displaystyle=\frac{\Gamma{\left(\frac{n_{Y}+1}{2}\right)}}{\pi\sigma_{X}\sqrt{2n_{Y}}\Gamma\left(\frac{n_{Y}}{2}\right)}$
(33)
$\displaystyle\times\int_{0}^{\infty}\frac{1}{x^{2}}\exp\Bigg{\\{}-\frac{(\log(x)-\mu_{X})^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}\left(1+\frac{z^{2}}{n_{Y}x^{2}}\right)^{-\frac{n_{Y}+1}{2}}dx.$

The PDF given in Eq. (33) has no closed form representation and requires
numerical calculations. However, using the independence assumption, one can
easily show that

$\mathbb{E}(Z)=0,~{}~{}Var(Z)=\frac{n_{Y}}{n_{Y}-2}\exp\Bigg{\\{}\sigma_{X}^{2}-1\Bigg{\\}}\exp\Bigg{\\{}2\mu_{X}+\sigma_{X}^{2}\Bigg{\\}},$
(34)

when $n_{Y}>2$. Similarly as for the Gaussian-Student’s t case, the variance
decreases to the variance of $X$ with $n_{Y}\rightarrow\infty$.

In Fig. 7 we plot the PDF and the corresponding distribution tail of the
random variable $Z$ for different values of the $n_{Y}$ parameter, while in
Fig. 8 we show a comparison of these three distributions. The picture is
similar as the one obtained for the Gaussian - Student’s t case (see Fig. 3)
with slightly heavier tails, especially for higher values of $n_{Y}$
parameters.

Figure 7: Distribution of the product of two independent random variables from
the log-normal and Student’s t distribution with $\mu_{X}=0$ and
$\sigma_{X}=1$ and different values of $n_{Y}$ parameter. Left panel: the PDF
of the random variable $Z$. Right panel: the distribution tail for the random
variable $Z$ (in log-log scale).  Figure 8: Left panel: the PDF of the random
variables $X$ (log-normal), $Y$ (Student’s t) and $Z$. Right panel: the
distribution tails. The parameters are: $\mu_{X}=0$ and $\sigma_{X}=1$ and
$n_{Y}=0.5$.

###  4.4 Log-normal and Pareto distributions

As the last case, assume that $X$ is a log-normally distributed random
variable with parameters $\mu_{X}=0$ and $\sigma_{X}>0$ and $Y$ is a Pareto
distributed random variable with parameters $a_{Y}>0$ and $\theta_{Y}>0$.
Moreover, assume that $X$ and $Y$ are independent.

######  Lemma 3.

The random variable $Z$ defined as a product of $X$ and $Y$ has the following
PDF

$\displaystyle f_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{\theta_{Y}}{\sigma_{X}z}\phi\left(\frac{\log(z/\theta_{Y})}{\sigma_{X}}\right)$
$\displaystyle+\frac{a_{Y}\theta_{Y}^{a_{y}}\exp\Bigg{\\{}\frac{a_{y}^{2}\sigma_{X}^{2}}{2}\Bigg{\\}}}{z^{a^{y}+1}}\Phi\left(\frac{\log(z/\theta_{Y})-a_{Y}\sigma_{X}^{2}}{\sigma_{X}}\right)$
$\displaystyle-\frac{\theta_{Y}^{a_{y}+1}\exp\Bigg{\\{}\frac{a_{y}^{2}\sigma_{X}^{2}}{2}\Bigg{\\}}}{\sigma_{X}z^{a^{y}+1}}\phi\left(\frac{\log(z/\theta_{Y})-a_{Y}\sigma_{X}^{2}}{\sigma_{X}}\right),~{}z>0,$

where $\phi(\cdot)$ and $\Phi(\cdot)$ are the PDF and CDF of the standard
Gaussian distribution, respectively.

The proof of this lemma is presented in Appendix B.

The expected value of $Z$ (when $a_{Y}>1$) and the variance of $Z$ (when
$a_{Y}>2$) are given by

$\mathbb{E}(Z)=\frac{\theta_{Y}a_{Y}}{a_{Y}-1}\exp\Bigg{\\{}\frac{\sigma_{X}^{2}}{2}\Bigg{\\}},~{}~{}Var(Z)=\frac{\theta_{Y}a_{Y}}{(a_{Y}-2)}\left(\exp\Bigg{\\{}\sigma_{X}^{2}\Bigg{\\}}-1\right)\exp\Bigg{\\{}\sigma_{X}^{2}\Bigg{\\}}.$

Here, both marginal variables can take only positive values. Hence, the
product variable $Z$ is also positive and its expected value (if it exists) is
greater than 0, $\mathbb{E}(Z)>0$. The expected value, as well as, the
variance of $Z$ are the products of the corresponding moments of the marginal
distributions. Their existence is directly related to the existence of the
moments of the Pareto marginal distribution.

In Fig. 9 we plot the PDF of the random variable $Z$ and the corresponding
distribution tail for different values of $a_{Y}$ parameter, while in Fig. 10
we demonstrate the comparison of the $X$, $Y$ and $Z$ distributions. As can be
observed the tail parameter of the marginal Pareto distribution has a large
impact on the tail of the product distribution.

Figure 9: Distribution of the product of two independent random variables from
the log-normal and Pareto distribution with $\mu_{X}=0$ and
$\sigma_{X}=\theta_{Y}=1$ and different values of $a_{Y}$ parameter. Left
panel: the PDF of the random variable $Z$. Right panel: the distribution tail
for the random variable $Z$ (in log-log scale).  Figure 10: Left panel: the
PDF of the random variables $X$ (log-normal), $Y$ (Pareto) and $Z$. Right
panel: the distribution tails. The parameters are equal: $\mu_{X}=0$ and
$\sigma_{X}=\theta_{Y}=1$ and $a_{Y}=0.5$.

##  5 Parameters estimation - simulation study

Based on the formulas for the PDF, $f_{Z}(z)$, derived in the previous
sections, we illustrate how the parameters of the product distribution can be
estimated. To this end, we simulate samples of random vectors
$((X_{1},Y_{1}),(X_{2},Y_{2}),...,(X_{N},Y_{N}))$ from the analyzed
distributions and calculate the product of each simulated pair,
$Z_{i}=X_{i}Y_{i},i=1,2,...,N$. The Gaussian random vectors are generated
using the Cholesky decomposition. The simulation of the vectors from the log-
normal and dependent Student’s t distribution is based on the relation with
the Gaussian distribution. In the case of dependent Pareto variables, the
method based on conditional distributions is used, based on the fact that
$F_{X,Y}(x,y)=F_{X}(x)F_{Y\mid X}(y\mid x)$. First, $X$ is generated using the
marginal distribution $F_{X}(x)$. Next, $Y$ is generated using the conditional
distribution $F_{Y\mid X}(y\mid x=X)$ with $X$ from the first step. For both
steps, the inverse CDF method is applied. The independent Student’s t,
independent Pareto, Gaussian-Student’s t and Gaussian-Pareto vectors
simulation is based on the corresponding one-dimensional distributions.

The estimation of parameters is based on the maximum likelihood method. Thus,
we have

$\hat{\Theta}=\text{argmax}_{\Theta}L(Z_{1},Z_{2},....,Z_{N}\mathchar
24635\relax\;\Theta)=\text{argmax}_{\Theta}\prod_{i=1}^{N}f_{Z}(Z_{i}\mathchar
24635\relax\;\Theta),$ (36)

where $\Theta$ is the vector of parameters and $f_{Z}(z)$ is the corresponding
product probability density function. Since analytical solutions do not exist
in any of the considered cases, the maximization is performed numerically.
Note that for the product of the multivariate Gaussian distribution with
$\mu_{X}=\mu_{Y}=0$ the method of moments estimators can be also
straightforwardly derived, using the exact formulas for the moments. Note also
that the scale parameters of the individual marginal distributions can not be
inferred separately from the product, as they jointly yield the scale of the
resulting one-dimensional variable, e.g., for the Gaussian distribution we
have $\sigma_{X}\sigma_{Y}$, for the log-normal distribution
$\sigma_{X}^{2}+\sigma_{Y}^{2}+2\rho\sigma_{X}\sigma_{Y}$, while for the
independent Pareto $\theta_{X}\theta_{Y}$.

In Fig. 11 we plot the boxplots of the errors of the shape parameter
estimation for the product of the Student’s t (i.e., $\hat{n}-n$) and Pareto
(i.e. $\hat{a}-a$) distributions. The dependent variables case (see Eq. (15)
for Student’s t and Eq. (21) for Pareto) as well as the independent one (see
Eq. (18) for Student’s t and Lemma 1 for Pareto) are considered. The other
parameters are set to $\rho=0$, and $\theta_{X}=\theta_{Y}=1$. In the
independent Pareto case, the same shape parameter for both variables,
$a_{X}=a_{Y}=a$, is considered. The boxplots are plotted for two simulated
values of the shape parameter, namely, $n=0.5$ or $n=8$ and $a=0.5$ or $a=8$.
The obtained error distribution is spread around 0, with much larger
deviations in the lighter tails case (i.e., $n=8$ and $a=8$). Such an effect
might be caused by the fact that for larger values of the shape parameters the
differences between distributions become smaller. In the case of the Student’s
t distribution, the errors are not symmetric around zero with more cases of
overestimation of the parameter $n$. In the case of the Pareto distribution,
there is no visible asymmetry.

Figure 11: Boxplots of the errors of the degrees of freedom estimator,
$\hat{n}$ and the tail parameter, $\hat{a}$, for the Student’s t and Pareto
distribution products, respectively. Left panels: results for the dependent
and independent Student’s t distribution with $\rho=0$ and $n=0.5$ or $n=8$.
Right panels: results for the dependent and independent Pareto distribution
with $\theta_{X}=\theta_{Y}=1$ and $a=a_{X}=a_{Y}=0.5$ or $a=a_{X}=a_{Y}=8$.
The length of each sample was equal to 1000, while the number of repetitions
was equal to 100.

Finally, in Fig. 12 we plot the boxplots of the errors of the shape parameters
for the products of different marginal distributions, namely, the Gaussian -
Student’s t, the Gaussian - Pareto, the log-normal - Student’s t and the log-
normal - Pareto case. For the Gaussian and log-normal distributions we assume
$\mu_{X}=0$ and $\sigma_{X}=1$, while the scale parameter of the Pareto
distribution is equal $\theta_{Y}=1$. The errors are analyzed in two cases
representing the infinite- ($n=0.5$ for Student’s t distribution or
$a_{Y}=0.5$ for Pareto distribution) as well as finite-variance ($n=8$ for
Student’s t distribution or $a_{Y}=8$ for Pareto distribution). The obtained
estimation results are similar to the purely Student’s t or Pareto
distributions (see Fig. 11). The higher errors are obtained for the higher
values of the $n$ and $a$ parameters. Furthermore, the effect of
overestimation of the Student’s t degrees of freedom can be noticed.

Figure 12: Boxplots of the errors of the degrees of freedom $\hat{n}$ and the
tail parameter $\hat{a}$ estimators for the products of the Gaussian or log-
normal distribution and Student’s t or Pareto distribution, respectively. The
parameters of the Gaussian and log-normal distribution were set to $\mu_{X}=0$
and $\sigma_{X}=1$. The Student’s t distribution was simulated with $n=0.5$ or
$n=8$ degrees of freedom, while the Pareto distribution with $\theta=1$ and
$a=0.5$ or $a=8$. The length of each sample was equal to 1000, while the
number of repetitions was equal to 100.

##  6 Real data application - distribution of electricity transaction values

In this section, we demonstrate the possible application of the theoretical
results discussed in the previous sections to a real-data case. We use the
transactions data from the German electricity market settled in the EPEX
energy exchange. Each transaction is characterized by two values: the volume
of sold energy (in MWh) and the price (in EUR/MWh). The final transaction
value, being the amount of the total profit for the energy seller or a total
cost for energy buyer, is the product of these two variables. Hence, knowing
the product distribution is important for profit/costs planning in energy
companies.

The data comes from a continuous trading on the intraday market. A transaction
is settled each time two bid and sell offers meet. Hence, each data point
corresponds to a different offer and usually a different market participant,
so the sample points can be assumed independent. One of the main
characteristics of the electricity market is its seasonality on the yearly,
weekly, and daily level RWeron_energy . To avoid the possible influence of the
transaction time on its distribution, we analyze separately the transactions
being settled in different hours. The data points within one hour are assumed
to be identically distributed.

We analyze vectors $\\{(x_{1},y_{1}),(x_{2},y_{2}),...,(x_{n},y_{n})\\}$,
where $x_{i}$ is the volume and $y_{i}$ is the price of the $i$-th transaction
within a given hour and $n$ is the number of transactions during this hour. We
also analyze a sample of the transaction values being a product of each
$x_{i}$ and $y_{i}$, i.e. $\\{x_{1}y_{1},x_{2}y_{2},...,x_{n}y_{n}\\}$. For an
illustration, we have chosen two representative hours, namely, hour 14 from
20th December 2020 and hour 8 from 15th March 2020. The first case shows a
typical picture that is observable for most hours, while the second case
illustrates the less frequent but typical for the German electricity market
situation where some of the transaction prices are negative. Negative prices
are a unique feature of electricity markets caused by the limited ability to
store electricity and the fast development of production from renewable energy
sources NegativePrices . If there is a short-term oversupply of electricity
due, for example, to wind or solar production, the producers from conventional
energy sources might be willing to pay for the reception of electricity
instead of stopping the production units.

The corresponding PDFs are plotted in Figs. 13 and 14 for 20th December and
15th March, respectively. The correlation between the volume and price samples
is not significant. Hence, we assume that the corresponding $X$ and $Y$ random
variables are not correlated. Since the volume can not be negative, the only
distributions from the ones analyzed in the paper that can be fitted to the
volume sample are the log-normal and Pareto. For the price sample, the
Gaussian, log-normal (for positive data) and Student’t t with location and
scale parameters are fitted. The resulting densities are plotted in the
corresponding panels of Figs. 13 and 14.

Figure 13: Probability distribution of the volume (top panel), price (middle
panel) and their product, i.e. the transaction value (bottom panel) from the
continuous intraday energy market data on 20th December 2020, hour 14. The
fitted PDFs are also plotted. The transaction value densities are fitted in
two ways: separately to the $x$ (price) and $y$ (volume) data (denoted by
’$(x,y)$ fit’) or to the product $xy$ (transaction value) data (denoted by
’$xy$ fit’). Figure 14: Probability distribution of the volume (top panel),
price (middle panel) and their product, i.e. the transaction value (bottom
panel) from the continuous intraday energy market data on 15th March 2020,
hour 8. The fitted PDFs are also plotted. The transaction value densities are
fitted in two ways: separately to the $x$ (price) and $y$ (volume) data
(denoted by ’$(x,y)$ fit’) or to the product $xy$ (transaction value) data
(denoted by ’$xy$ fit’).

For both analyzed hours, the log-normal distribution density function
resembles the shape of the volume histogram. On the other hand, the Pareto
distribution clearly overestimates the probability of small volumes. Hence,
for the product analysis, we will only consider the log-normal distribution
for the first coordinate. Looking at the price distribution for the data from
hour 14 on 20th December 2020 (see Fig. 13), we can observe that only the
Student’s t PDF resembles the shape of the obtained histogram, especially
around the mean, where the Gaussian and log-normal probabilities are
underestimated. The picture for the second considered data set, i.e., the
price distribution from hour 8 on 15th March 2020 (see Fig. 14), is different.
First, there is a significant probability of obtaining negative values. Hence,
in this case we do not fit the log-normal distribution, which can take only
positive values. Second, the Gaussian and the Student’s t PDF produce a
similar fit. Recall that with increasing degrees of freedom in the latter
case, the distribution tends to the Gaussian one. The tails for this hour are
lighter than for the 20th December data. Overall, from the set of considered
distributions, only the Student’s t can be well fitted to the prices from both
analyzed hours.

Next, we analyze the resulting product, i.e., the transaction value
distribution. To this end, we proceed in two ways. Firstly, we use the
parameters estimated for the one-dimensional samples of the random variables
$X$ and $Y$ (i.e., volumes and prices) and use the formulas for the product
PDF derived in Sections 2-4. Based on the results obtained for the one-
dimensional samples we show only the product of log-normal distribution or
log-normal and Student’s t distribution (log-normal-Student’s t). Secondly, we
also fit the derived PDFs to the sample of the product $XY$. We can observe
that the final product PDF obtained by these two ways in the case of log-
normal-Student’s t overlaps and resembles the shape of the sample histogram,
confirming a good fit. As mentioned before, due to the negative prices
apparent in the second analyzed hour, the log-normal distribution can be
fitted only to the first dataset. In this case, we can observe a discrepancy
between the density obtained using the $(X,Y)$ coordinates and its product
$XY$. Comparing the obtained shapes of the distribution for both hours, we can
see a clear difference between these cases. The transaction values for hour 8
on 15th March 2020 take both negative and positive values, with long left
tails of the distribution. On the other hand, there are no negative
transaction values for hour 14 on 20th December 2020 and the distribution is
right skewed. Overall, only the log-normal-Student’s t case from the
considered distributions set is flexible enough to be reasonably applied to
both analyzed representative hours and the obtained distribution resembles the
data well.

##  7 Conclusions

In this paper, we have discussed the distribution of a random variable that is
a product of two continuous random variables. The main attention was paid to
the influence of the parameters of the marginal random variables on the final
product characteristics. We have considered exemplary distributions belonging
to the classes of finite as well as infinite-variance distributions. For both
cases, we have discussed how the correlation coefficient between the marginal
random variables influences the probabilistic properties of the product. In
the case of the Gaussian and log-normal distributions, the non-zero
correlation coefficient indicates the statistical dependence of the random
variables, while in the second case, i.e., the Student’s t and Pareto
distributions, this statement is not true. The most interesting case was the
product of the random variables coming from different classes of
distributions, for which we have derived the explicit form of the PDF for the
Gaussian-Pareto and the log-normal-Pareto case.

The theoretical results were applied in the proposed estimation methodology.
We used a general approach based on the maximum likelihood technique. The
presented Monte Carlo simulations clearly indicate the effectiveness of the
algorithm. Finally, the real data analysis was presented. Based on the data
from continuous trading on the German energy market, we have shown a good
reasonable fit of the product of log-normal and Student’s t distribution to
the transaction values. Since the transaction value is the final profit/cost
for a trader, finding a proper density describing its distribution, which is
also consistent with the prices and volumes data, can help an energy market
participant in strategy planning.

Another potential application of the proposed methodology could be the market
risk area in metals and mining business. Mining companies are exposed to two
or more market risk factors, like metal prices and currency exchange rates.
These factors behavior is often characterized by non-Gaussian distributions,
what can be reflected by the discussed in this paper, log-normal and Student’s
t distributions. From a business perspective of an international mining
company, which trades the excavated resources in different than national
currency, it is valuable to analyse the selling price also in the national
currency, that is a product of the commodity price (usually quoted in USD) and
USD/national currency exchange rate. A case study related to the modelling of
the copper prices for a polish mining company one can find in reso . It has
been shown that the behavior of metal price in PLN exhibits specific
characteristics, that follow directly from the properties of the individual
variables. These properties need to be reflected in optimizing strategies
aimed at mitigation of the unacceptable for company market risk.

## Acknowledgments

The work of A.W. was supported by National Center of Science under Opus Grant
2020/37/B/HS4/00120 ”Market risk model identification and validation using
novel statistical, probabilistic, and machine learning tools”. J.J.
acknowledges a support of NCN Sonata Grant No. 2019/35/D/HS4/00369.

## Data Availability

The datasets generated during the current study are available from the
corresponding author on reasonable request. The energy transactions data
analysed in this study are available from the EPEX SPOT exchange.

## References

  *   * (1) Nadarajah, S.: Exact distribution of the product of two or more logistic random variables. Methodology and Computing in Applied Probability 11, 651–660 (2008)
  * (2) Nadarajah, S.: Some algebra for Pearson type vii random variables. Bulletin of The Korean Mathematical Society 45, 339–353 (2008)
  * (3) Nadarajah, S.: On the product xy for some elliptically symmetric distributions. Statistics & Probability Letters 75, 67–75 (2005)
  * (4) Garg, M., Sharma, A., Manohar, P.: The distribution of the product of two independent generalized trapezoidal random variables. Communications in Statistics - Theory and Methods 45, 6369–6384 (2016)
  * (5) M. Ahsanullah, M.S. B. M. Golam Kibria: Normal and Student’s T Distributions and Their Applications, pp. 7–102. Atlantis Press, Netherlands (2014)
  * (6) Nadarajah, S., Dey, D.K.: On the product and ratio of t random variables. Applied Mathematics Letters 19(1), 45–55 (2006)
  * (7) Li, Y., He, Q., Blum, R.S.: On the product of two correlated complex Gaussian random variables. IEEE Signal Processing Letters 27, 16–20 (2020)
  * (8) Seijas-Macías, A., Oliveira, A.: An approach to distribution of the product of two normal variables. Discussiones Mathematicae Probability and Statistics 32, 87–99 (2012)
  * (9) Nadarajah, S.: The product t density distribution arising from the product of two Student’s t PDFs. Statistical Papers 50, 605–615 (2009)
  * (10) Malik, H.J., Trudel, R.: Probability density function of the product and quotient of two correlated exponential random variables. Canadian Mathematical Bulletin 29(4), 413–418 (1986)
  * (11) Homei, H.: The stochastic linear combination of dirichlet distributions. Communications in Statistics - Theory and Methods 50, 2354–2359 (2019)
  * (12) Tang, J., Gupta, A.: On the distribution of the product of independent beta random variables. Statistics & Probability Letters 2, 165–168 (1984)
  * (13) Bhargava, R., Khatri, C.: The distribution of product of independent beta random variables with application to multivariate analysis. Annals of the Institute of Statistical Mathematics 33, 287–296 (1981)
  * (14) Nadarajah, S.: On the product of generalized Pareto random variables. Applied Economics Letters 15, 253–259 (2008)
  * (15) Pham-Gia, T., Turkkan, N.: The product and quotient of general beta distributions. Statistical Papers 43(4), 537–550 (2002)
  * (16) Nadarajah, S., Kotz, S.: A note on the product of normal and laplace random variables. Brazilian Journal of Probability and Statistics 19(1), 33–38 (2005)
  * (17) Nadarajah, S., Kotz, S.: On the linear combination, product and ratio of normal and Laplace random variables. J. Frankl. Inst. 348, 810–822 (2011)
  * (18) Nadarajah, S., Kotz, S.: On the product and ratio of gamma and Weibull random variables. Econometric Theory 22(2), 338–344 (2006)
  * (19) Nadarajah, S., Kotz, S.: On the product and ratio of gamma and beta random variables. Allgemeines Statistisches Archiv 89, 435–449 (2005)
  * (20) Nadarajah, S.: Sum, product and ratio of Pareto and gamma variables. Journal of Statistical Computation and Simulation 80, 1071–1082 (2010)
  * (21) Galambos, J., Simonelli, I.: Products of Random Variables: Applications to Problems of Physics and to Arithmetical Functions (1st Ed.). CRC Press, Boca Raton (2004)
  * (22) Podolski, H.: The distribution of a product of n independent random variables with generalized gamma distribution. Demonstratio Mathematica 4, 119–124 (1972)
  * (23) Wilson, P.S., Toumi, R.: A fundamental probability distribution for heavy rainfall. Geophysical Research Letters 32(14) (2005)
  * (24) Cigizoglu, H.K., Bayazit, M.: A generalized seasonal model for flow duration curve. Hydrological Processes 14(6), 1053–1067 (2000)
  * (25) Ly, S., Pho, K.-H., Ly, S., Wong, W.-K.: Determining distribution for the product of random variables by using copulas. Risks 7(1) (2019)
  * (26) Salo, J., El-Sallabi, H.M., Vainikainen, P.: The distribution of the product of independent Rayleigh random variables. IEEE Transactions on Antennas and Propagation 54(2), 639–643 (2006)
  * (27) Yang, Y., Wang, Y.: Tail behavior of the product of two dependent random variables with applications to risk theory. Extremes 16, 55–74 (2013)
  * (28) Bhargav, N., da Silva, C.R.N., Chun, Y.J., Leonardo, E.J., Cotton, S.L., Yacoub, M.D.: On the product of two $\kappa$ – $\mu$ random variables and its application to double and composite fading channels. IEEE Transactions on Wireless Communications 17(4), 2457–2470 (2018)
  * (29) Nadarajah, S., Kotz, S.: Sociological models based on Fréchet random variables. Quality & Quantity 42, 89–95 (2008)
  * (30) Rohatgi, V.K., Saleh, A.K.M.E.: An Introduction to Probability and Statistics. Wiley Series in Probability and Statistics. John Wiley & Sons, New Jersey (2015)
  * (31) Mardia, K.V.: Multivariate Pareto distributions. The Annals of Mathematical Statistics 33(3), 1008–1015 (1962)
  * (32) de la Peña, V.H., Ibragimov, R., Sharakhmetov, S.: Characterizations of joint distributions, copulas, information, dependence and decoupling, with applications to time series. Lecture Notes-Monograph Series 49, 183–209 (2006)
  * (33) Jeong, B., Lee, W., Kim, D.-S., H, H.S.: Copula-based approach to synthetic population generation. PLoS ONE 11(8), 0159496 (2016)
  * (34) Wyłomańska, A., Chechkin, A., Gajda, J., Sokolov, I.M.: Codifference as a practical tool to measure interdependence. Physica A: Statistical Mechanics and its Applications 421, 412–429 (2015)
  * (35) Slezak, J., Metzler, R., Magdziarz, M.: Codifference can detect ergodicity breaking and non-gaussianity. New Journal of Physics 21(5), 053008 (2019)
  * (36) Samorodnitsky, G., Taqqu, M.: Stable Non-Gaussian Random Processes: Stochastic Models with Infinite Variance. Chapman and Hall, New York (1994)
  * (37) Nowicka, J.: Asymptotic behavior of the covariation and the codifference for ARMA models with stable innovations. Communications in Statistics. Stochastic Models 13(4), 673–685 (1997)
  * (38) Roussas, G.G.: Joint and conditional p.d.f.’s, conditional expectation and variance, moment generating function, covariance, and correlation coefficient. In: An Introduction to Probability and Statistical Inference, 135–186 (2015)
  * (39) Gaunt, R.E.: A note on the distribution of the product of zero-mean correlated normal random variables. Statistica Neerlandica 73(2), 176–179 (2018)
  * (40) Aroian, L.A., Taneja, S.V., Cornwell, L.W.: Mathematical forms of the distribution of the product of two normal variables. Communications in Statistics - Theory and Methods 7(2), 165–172 (1978)
  * (41) Craig, C.C.: On the frequency function of $xy$. The Annals of Mathematical Statistics 7(1), 1–15 (1936)
  * (42) Aitchison, J., Ho, C.H.: The multivariate Poisson-log normal distribution. Biometrika 76(4), 643–653 (1989)
  * (43) Yerel, S., Konuk, A.: Bivariate lognormal distribution model of cutoff grade impurities: A case study of magnesite ore deposit. Scientific Research and Essay 4(12), 1500–1504 (2009)
  * (44) Lai, C.D., Balakrishnan, N.: Continuous Bivariate Distributions. Springer, New York (2009)
  * (45) Cochran, W.G.: The distribution of quadratic forms in a normal system, with applications to the analysis of covariance. Mathematical Proceedings of the Cambridge Philosophical Society 30(2), 178–191 (1934)
  * (46) Hossain, A.M., Zimmer, W.J.: Comparisons of methods of estimation for a Pareto distribution of the first kind. Communications in Statistics - Theory and Methods 29(4), 859–878 (2000)
  * (47) Weron, R.: Modeling and Forecasting Electricity Loads and Prices : a Statistical Approach / Rafał Weron. Wiley finance series. John Wiley & Sons, Chichester, England; Hoboken, New York (2006)
  * (48) August, B., Horsch, A.: Negative market prices on power exchanges: Evidence and policy implications from Germany. The Electricity Journal 33(3), 106716 (2020)
  * (49) Bielak, L., Grzesiek, A., Janczura, J., Wyłomańska, A.: Market risk factors analysis for an international mining company. multi-dimensional heavy-tailed-based modelling. Resources Policy 74, 102308 (2021)

## Appendix A

Proof of Lemma 2.
Let us first note that the CDF of $Y$ is given by

$\displaystyle F_{Y}(y)=1-\theta_{Y}^{a_{Y}}y^{-a_{Y}},~{}y>\theta_{Y}.$ (37)

Thus, the CDF of $Z$ takes the form

$\displaystyle F_{Z}(z)$ $\displaystyle=$ $\displaystyle
P(XY<z)=\int_{-\infty}^{\infty}P(Yx<z)f_{X}(x)dx$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{\infty}P(Yx<z)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{0}P(Yx<z)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}P(Yx<z)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{0}P\left(Y>\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}P\left(Y<\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx.$

We consider separately $z>0$, $z<0$ and $z=0$. For $z>0$ one obtains

$\displaystyle F_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{0}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}F_{Y}\left(\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{0}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{z/\theta_{Y}}\left(1-\theta_{Y}^{a_{Y}}\left(\frac{x}{z}\right)^{a_{Y}}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$ $\displaystyle
F_{X}\left(\frac{z}{\theta_{Y}}\right)-\frac{\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}}}\int_{0}^{z/\theta_{Y}}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx.$

Now, calculating the derivative of $F_{Z}(z)$ with respect to $z$ for $z>0$
one has

$\displaystyle f_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{1}{\theta_{Y}}f_{X}\left(\frac{z}{\theta_{Y}}\right)+\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}+1}}\int_{0}^{z/\theta_{Y}}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle-\frac{\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}}\theta_{Y}}\left(\frac{z}{\theta_{Y}}\right)^{a_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}\theta_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle+\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}+1}}\int_{0}^{z/\theta_{Y}}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle-\frac{1}{\sqrt{2\pi}\sigma_{X}\theta_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}+1}}\int_{0}^{z/\theta_{Y}}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}z^{a_{Y}+1}}2^{(a_{Y}-1)/2}$
$\displaystyle\times\left(\frac{z}{\theta_{Y}}\right)^{a_{Y}+1}\left(\frac{\theta_{Y}\sigma_{X}}{z}\right)^{a_{Y}+1}\left(\Gamma\left(\frac{a_{Y}+1}{2}\right)-\Gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma^{2}\theta_{Y}^{2}}\right)\right)$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}z^{a_{Y}+1}}2^{(a_{Y}-1)/2}\left(\Gamma\left(\frac{a_{Y}+1}{2}\right)-\Gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma^{2}\theta_{Y}^{2}}\right)\right)$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}z^{a_{Y}+1}}2^{(a_{Y}-1)/2}\gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma^{2}\theta_{Y}^{2}}\right),$

where $\gamma(a,x)$ is the upper incomplete Gamma function and
$\Gamma(a,x)=\Gamma(a)-\gamma(a,x)$ is the lower incomplete Gamma function.
For $z<0$ the CDF of $Z$ is given by

$\displaystyle F_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{0}P\left(Y>\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{z/\theta_{Y}}P\left(Y>\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{z/\theta_{Y}}^{0}P\left(Y>\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$ $\displaystyle
F_{X}\left(\frac{z}{\theta_{Y}}\right)+\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{z/\theta_{Y}}^{0}\theta_{Y}^{a_{Y}}\left(\frac{x}{z}\right)^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$ $\displaystyle
F_{X}\left(\frac{z}{\theta_{Y}}\right)+\frac{\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}(-z)^{a_{y}}}\int_{z/\theta_{Y}}^{0}(-x)^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$ $\displaystyle
F_{X}\left(\frac{z}{\theta_{Y}}\right)+\frac{\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}(-z)^{a_{y}}}\int^{-z/\theta_{Y}}_{0}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx.$

Now, taking the derivative of $F_{Z}(z)$ with respect to $z$ for $z<0$ we
obtain the following formula for corresponding PDF

$\displaystyle f_{Z}(z)$ $\displaystyle=$ $\displaystyle
f_{X}\left(\frac{z}{\theta_{Y}}\right)-\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}(-z)^{a_{y}+1}}\int^{-z/\theta_{Y}}_{0}x^{a_{Y}}\exp\Bigg{\\{}-\frac{x^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle-\frac{\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}(-z)^{a_{y}}\theta_{Y}}\left(-\frac{z}{\theta_{Y}}\right)^{a_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}\theta_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle+\frac{a_{Y}\theta_{Y}^{a_{Y}}}{\sqrt{2\pi}\sigma_{X}(-z)^{a_{y}+1}}2^{(a_{Y}-1)/2}\left(-\frac{z}{\theta_{Y}}\right)^{a_{Y}+1}\left(-\frac{\theta_{Y}\sigma_{X}}{z}\right)^{a_{Y}+1}$
$\displaystyle\times\left(\Gamma\left(\frac{a_{Y}+1}{2}\right)-\Gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\right)\right)$
$\displaystyle-\frac{1}{\sqrt{2\pi}\sigma_{X}\theta_{Y}}\exp\Bigg{\\{}-\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\Bigg{\\}}$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}(-z)^{a_{Y}+1}}2^{(a_{Y}-1)/2}\left(\Gamma\left(\frac{a_{Y}+1}{2}\right)-\Gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\right)\right)$
$\displaystyle=$
$\displaystyle\frac{a_{Y}\theta_{Y}^{a_{Y}}\sigma_{X}^{a_{Y}}}{\sqrt{2\pi}(-z)^{a_{Y}+1}}2^{(a_{Y}-1)/2}\gamma\left(\frac{a_{Y}+1}{2},\frac{z^{2}}{2\sigma_{X}^{2}\theta_{Y}^{2}}\right).$

The last case is $z=0$. In this case, the CDF of $Z$ is given by

$\displaystyle F_{Z}(0)=P(XY<0)=P(X<0)=\frac{1}{2}.$

One can also show that

$\displaystyle\lim_{z\rightarrow 0+}F_{Z}(z)=\lim_{z\rightarrow
0-}F_{Z}(z)=\frac{1}{2}=F_{Z}(0).$

Thus, finally we obtain the thesis. $\Box$

## Appendix B

Proof of Lemma 3.
Using the same reasoning as in the proof of Lemma 2 one obtains that the CDF
of $Z$ takes the following form for $z>0$

$\displaystyle F_{Z}(z)$ $\displaystyle=$ $\displaystyle
P(XY<z)=\int_{-\infty}^{\infty}P(Yx<z)f_{X}(x)dx$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}\frac{1}{x}P(Yx<z)\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}\frac{1}{x}P\left(Y<\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx.$

Thus, from (37) we obtain for $z>0$

$\displaystyle F_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{\infty}\frac{1}{x}F_{Y}\left(\frac{z}{x}\right)\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{z/\theta_{Y}}\frac{1}{x}\left(1-\theta_{Y}^{a_{Y}}\left(\frac{x}{z}\right)^{a_{Y}}\right)\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{0}^{z/\theta_{Y}}\frac{1}{x}\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx$
$\displaystyle-\frac{\theta_{Y}^{a_{y}}}{\sqrt{2\pi}\sigma_{X}z^{a^{y}}}\int_{0}^{z/\theta_{Y}}x^{a_{Y}-1}\exp\Bigg{\\{}-\frac{\log(x)^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}dx.$

Now, taking the substitution $\log(x)=u$ in the both above integrals, we
obtain

$\displaystyle F_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{1}{\sqrt{2\pi}\sigma_{X}}\int_{-\infty}^{\log(z/\theta_{Y})}\exp\Bigg{\\{}-\frac{u^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}du$
$\displaystyle-\frac{\theta_{Y}^{a_{y}}}{\sqrt{2\pi}\sigma_{X}z^{a^{y}}}\int_{-\infty}^{\log(z/\theta_{Y})}\exp\Bigg{\\{}ua_{y}-\frac{u^{2}}{2\sigma_{X}^{2}}\Bigg{\\}}du.$

To make the calculations simpler, in the first integral we put the
substitution $w=u/\sigma_{X}$ and in the second one
$w=(u-\sigma_{X}^{2}a_{Y})/\sigma_{X}$. Then we obtain

$\displaystyle F_{Z}(z)$ $\displaystyle=$
$\displaystyle\int_{-\infty}^{\frac{\log(z/\theta_{Y})}{\sigma_{X}}}\frac{1}{\sqrt{2\pi}}\exp\Bigg{\\{}-\frac{w^{2}}{2}\Bigg{\\}}dw$
$\displaystyle-\frac{\theta_{Y}^{a_{y}}\exp\Bigg{\\{}\frac{a_{y}^{2}\sigma_{X}^{2}}{2}\Bigg{\\}}}{z^{a^{y}}}\int_{-\infty}^{\frac{\log(z/\theta_{Y})-a_{Y}\sigma_{X}^{2}}{\sigma_{X}}}\frac{1}{\sqrt{2\pi}}\exp\Bigg{\\{}-\frac{w^{2}}{2}\Bigg{\\}}dw.$

Calculating the derivative of $F_{Z}(z)$ with respect to $z>0$ one has

$\displaystyle f_{Z}(z)$ $\displaystyle=$
$\displaystyle\frac{\theta_{Y}}{\sigma_{X}z}\phi\left(\frac{\log(z/\theta_{Y})}{\sigma_{X}}\right)+\frac{a_{Y}\theta_{Y}^{a_{y}}\exp\Bigg{\\{}\frac{a_{y}^{2}\sigma_{X}^{2}}{2}\Bigg{\\}}}{z^{a^{y}+1}}\Phi\left(\frac{\log(z/\theta_{Y})-a_{Y}\sigma_{X}^{2}}{\sigma_{X}}\right)$
$\displaystyle-\frac{\theta_{Y}^{a_{y}+1}\exp\Bigg{\\{}\frac{a_{y}^{2}\sigma_{X}^{2}}{2}\Bigg{\\}}}{\sigma_{X}z^{a^{y}+1}}\phi\left(\frac{\log(z/\theta_{Y})-a_{Y}\sigma_{X}^{2}}{\sigma_{X}}\right),$

where $\phi(\cdot)$ and $\Phi(\cdot)$ are the PDF and CDF of the standard
Gaussian distribution, respectively. $\Box$