Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
dynare
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Stéphane Adjemian
dynare
Commits
291d8617
Verified
Commit
291d8617
authored
1 year ago
by
Stéphane Adjemian
Browse files
Options
Downloads
Patches
Plain Diff
Cosmetic change (doc header).
[skip ci]
parent
ca10e3dc
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
matlab/pac-tools/a2alpha.m
+13
-13
13 additions, 13 deletions
matlab/pac-tools/a2alpha.m
with
13 additions
and
13 deletions
matlab/pac-tools/a2alpha.m
+
13
−
13
View file @
291d8617
...
...
@@ -3,26 +3,26 @@ function alpha = a2alpha(a)
% Computes the m alpha coefficients from the m a coefficients of the PAC model.
%
% INPUTS
% - a [double] m
*
1 vector of coefficients.
% - a [double] m
×
1 vector of coefficients.
%
% OUTPUTS
% - alpha [double] m
*
1 vector of coefficients.
% - alpha [double] m
×
1 vector of coefficients.
%
% NOTES
%
% Given the current estimate of the PAC parameters a
_0
, a
_1
, ..., a
_{m-1}
, the routine does the following:
% Given the current estimate of the PAC parameters a
₀
, a
₁
, ..., a
ₘ₋₁
, the routine does the following:
%
%
\alpha_{m} = a_{m-1}
%
\alpha_{m-1} = a_{m-2}-a_{m-1}
%
\alpha_{m-2} = a_{m-3}-a_{m-2}
%
...
%
\alpha_3 = a_2-a_3
%
\alpha_2 = a_1-a_2
%
\alpha_1 = a_0-a_1-
1
%
αₘ = aₘ₋₁
%
αₘ₋₁ = aₘ₋₂ - aₘ₋₁
%
⋮
%
αᵢ = aᵢ₋₁ - aᵢ ≡ - Δaᵢ
%
⋮
%
α₂ = a₁ - a₂
%
α₁ = a₀ - a₁ -
1
%
%
Note that the last elements of input a are (a_0, a_1, ..., a_{m-1}
).
%
Computed coefficients αᵢ define lag polynomial A(L) = 1 + α₁L + α₂L² + … + αₘ Lᵐ such that a₀ = A(1
).
% Copyright © 2018 Dynare Team
% Copyright © 2018
-2024
Dynare Team
%
% This file is part of Dynare.
%
...
...
@@ -53,4 +53,4 @@ alpha = zeros(m, 1);
% Compute the transformed parameters
alpha
(
m
)
=
a
(
m
);
alpha
(
2
:
m
-
1
)
=
a
(
2
:
m
-
1
)
-
a
(
3
:
m
);
alpha
(
1
)
=
a
(
1
)
-
a
(
2
)
-
1
;
\ No newline at end of file
alpha
(
1
)
=
a
(
1
)
-
a
(
2
)
-
1
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment