LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
kpcfit_ph_prony.m
1function PH=kpcfit_ph_prony(E,n)
2f = factorial(0:(2*n-1));
3m = kpcfit_hyper_charpoly(E,n);
4theta=roots(m); % determine eigenvalues from characteristic poly
5C = [];
6for i= 1:n
7 C(i,1:n) = f(i+1)*theta.^i;
8end
9M = (C\E(1:n)')'; % determine entry probabilities
10PH{1}=diag(-1./theta);
11PH{2}=-diag(-1./theta)*ones(n,1)*M;
12end