deriv_2nd_arma11 | R Documentation |
Obtain the second derivative of the ARMA(1,1) process.
deriv_2nd_arma11(phi, theta, sigma2, tau)
phi |
A |
theta |
A |
sigma2 |
A |
tau |
A |
A matrix
with:
The first column containing the second partial derivative with respect to phi;
The second column containing the second partial derivative with respect to theta;
The third column contains the second partial derivative with respect to sigma^2.
The fourth column contains the partial derivative with respect to phi and theta.
The fiveth column contains the partial derivative with respect to sigma^2 and phi.
The sixth column contains the partial derivative with respect to sigma^2 and theta.
Taking the second derivative with respect to phi yields:
d^2/dphi^2 nu[j]^2(phi, theta, sigma2) = (1/((phi - 1)^5*(phi + 1)^3*tau[j]^2))*(2*sigma2*((phi - 1)^2* ((phi + 1)^2*(theta^2*phi + theta*phi^2 + theta + phi)*tau[j]^2* (phi^(tau[j]/2) - 1)*phi^(tau[j]/2 - 2) + (phi^2 - 1)*(theta^2*(-phi) + theta*(phi^2 + 4*phi + 1) - phi)*tau[j]*(phi^(tau[j]/2) - 2)*phi^(tau[j]/2 - 2) - 2*(theta - 1)^2*(phi^tau[j] - 4*phi^(tau[j]/2) + 3)) - 12*(phi + 1)^2*(-((1/2)*(theta + 1)^2*(phi^2 - 1)*tau[j]) - (theta + phi)*(theta*phi + 1)* (phi^tau[j] - 4*phi^(tau[j]/2) + 3)) + 6*(phi + 1)*(phi - 1)*((1/2)*(theta + 1)^2*(phi^2 - 1)*tau[j] + (theta + phi)*(theta*phi + 1)*(phi^tau[j] - 4*phi^(tau[j]/2) + 3) + (phi + 1)*(-((theta + phi)*(theta*phi + 1)*tau[j]*(phi^(tau[j]/2) - 2)*phi^(tau[j]/2 - 1)) - theta*(theta + phi)*(phi^tau[j] - 4*phi^(tau[j]/2) + 3) - (theta*phi + 1)*(phi^tau[j] - 4*phi^(tau[j]/2) + 3) - (theta + 1)^2*phi*tau[j]))))
Taking the second derivative with respect to theta yields:
d^2/dtheta^2 nu[j]^2(phi, theta, sigma2) = (2*sigma2*(2*phi*(3 - 4*phi^(tau[j]/2) + phi^tau[j]) + (-1 + phi^2)*tau[j]))/((-1 + phi)^3*(1 + phi)*tau[j]^2)
Taking the second derivative with respect to sigma^2 yields:
d^2/dsigma2^2 nu[j]^2(phi, theta, sigma2) = 0
Taking the derivative with respect to sigma^2 and theta yields:
(2*((theta + 1)*(phi^2 - 1)*tau + (2*theta*phi + phi^2 + 1)* (phi^tau - 4*phi^(tau/2) + 3)))/((phi - 1)^3*(phi + 1)*tau^2)
Taking the derivative with respect to sigma^2 and phi yields:
(1/((-1 + phi)^4*(1 + phi)^2*tau[j]^2))* (2*((-1 + phi)*((-(theta + phi))*(1 + theta*phi)*(3 - 4*phi^(tau[j]/2) + phi^tau[j]) - (1/2)*(1 + theta)^2*(-1 + phi^2)*tau[j]) + 3*(1 + phi)*((-(theta + phi))*(1 + theta*phi)*(3 - 4*phi^(tau[j]/2) + phi^tau[j]) - (1/2)*(1 + theta)^2*(-1 + phi^2)*tau[j]) - (-1 + phi)*(1 + phi)*((-theta)*(theta + phi)*(3 - 4*phi^(tau[j]/2) + phi^tau[j]) - (1 + theta*phi)*(3 - 4*phi^(tau[j]/2) + phi^tau[j]) - (1 + theta)^2*phi*tau[j] - phi^(-1 + tau[j]/2)*(theta + phi)*(1 + theta*phi)*(-2 + phi^(tau[j]/2))*tau[j])))
Taking the derivative with respect to phi and theta yields:
d/dphi * d/dtheta nu[j]^2(phi, theta, sigma2) =(-(1/((-1 + phi)^4*(1 + phi)^2*tau[j]^2)))*2*sigma2*(2*(3 - 4*phi^(tau[j]/2) + phi^tau[j])* (1 + phi*(3 + phi + phi^2) + theta*(1 + phi*(2 + 3*phi))) + (2*(1 + theta)*(-1 + phi)*(1 + phi)^2 + 2*phi^(tau[j]/2 - 1)*(-1 + phi^2)* (1 + 2*theta*phi + phi^2) - phi^(tau[j] - 1)*(-1 + phi^2)* (1 + 2*theta*phi + phi^2))*tau[j])
James Joseph Balamuta (JJB)
deriv_2nd_arma11(.3, .4, 1, 2^(1:5))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.