1function [fit,m3pps] = m3pp_superpos_fitc(av, btv, binfv, ...
3% Fits k second-order M3PP[m_j] and superposes them into a
4% M3PP[m] of order k+1, with m = \sum_j=1^k m_j.
7% av: vector of length m with the per-process rates
8% btv: vector of length k with the per-process IDC(t)
9% binfv: vector of length k with the per-process IDC(inf)
10% m3tv: third moment of counts
12% tinf: near-infinite time scale
15% fit: result of the superposition, M3PP[m] of order k+1
16% m3pps: cell-array with the fitted and superposed second-order
25% fit m3pp[2] processes
28 mmpp = mmpp2_fitc(av(i), ...
29 btv(i), btv(i), binfv(i), ...
31 m3pps{i} = {mmpp{1},mmpp{2},mmpp{2}};
34% perform superposition
35fit = mmap_superpos(m3pps);
37fa = map_count_mean(fit,1);
38fprintf(
'Rate: input = %f, %f\n', a, fa);
39fav = mmap_count_mean(fit,1);
41 fprintf(
'Class %d, rate: input = %f, output = %f\n', i, av(i), fav(i));
43fbtv = mmap_count_var(fit,t) ./ (av * t);
45 fprintf(
'Class %d, IDC(%.2f): input = %f, output = %f\n', i, t, btv(i), fbtv(i));
47fbinfv = mmap_count_var(fit,tinf) ./ (av * tinf);
48fbinfv_limit = mmap_count_var(fit, 1e6) ./ (av * 1e6);
50 fprintf(
'Class %d, IDC(inf = %.2f): input = %f, output = %f, output_limit = %f\n', i, tinf, binfv(i), fbinfv(i), fbinfv_limit(i));