# Clarification on Akaike's IC (AIC) and BIC for Expectation Maximization with time-changing parameters

I apologize in advance for the trivial question, but I need a clarification on the following issue. Suppose I have a generic model in state-space form described as

$$x_{t+1}=\phi_{t} x_{t}+w_{t+1}$$ $$y_{t}=H_{t}x_{t}+v_{t}$$

Notice that all the parameters in $$\phi_{t}, H_{t}$$ as well as in $$Var(w_{t+1})$$ and $$Var(v_{t})$$ are allowed to be time-varying. Suppose that total number of parameters for each period of interest is indicated by k. Therefore, in the theoretical case where I want to run the Expectation Maximization algorithm to estimate all the model parameters, then the total number of parameters to be estimated is $$K=T*k$$. Applying the definition of AIC and BIC, we get

$$AIC=-2Loglik+2K=-2Loglik+2T*k$$ $$BIC=-2Loglik+ln(T)2K=-2Loglik+ln(T)2T*k$$

The problem is that, sometimes, I see general formulations of AIC and BIC where the total number of parameters K is divided by T. Therefore in this case, one should have:

$$AIC=-2Loglik+2K/T=-2Loglik+2T*k/T$$ $$BIC=-2Loglik+ln(T)2K/T=-2Loglik+ln(T)2T*k/T$$

My questions are:

Q1: if K must represent the total number of parameters to be estimated as per canonical definition of AIC, why dividing it by the number of periods? This uncertainty seems to be shared in part by this Stata guide that, at page 3, says "K is the number of parameters estimated. Some authors define the AIC as the expression above divided by the sample size".

Q2: in a multivariate settings like this one (where I have a total number of variables in the vectors $$y_{t}$$ and $$x_{t}$$ equal to N for each $$t$$), if I use the BIC, shall I substitute the canonical penalization $$ln(T)2*K$$ with $$ln(T*N)2*K$$ in order to incorporate the fact that the total number of datapoints is T for each of the N time series (instead of just T as in the univariate case)?

Do you have any references on the AIC/BIC for a dynamic regression like this? Many thanks

P.S.: Even if it doesn't deal with ICs, I post here a useful link for everybody interested in a good source for the general formulation of the Expectation Maximization, including the cases of time-varying parameters and/or external regressors with/without constraints https://cran.r-project.org/web/packages/MARSS/vignettes/EMDerivation.pdf