LINE Solver
MATLAB API documentation
Loading...
Searching...
No Matches
mmap_mixture_fit_mmap.m
1function [MMAP,PHs] = mmap_mixture_fit_mmap(mmap)
2% Fits a MMAP with m classes using a mixture of m^2 PH-distributions.
3% Each PH distribution represents the probability distribution conditioned
4% on the fact that the last arrival was of class i and the next arrival is
5% of class j.
6%
7% INPUT
8% - mmap: the MMAP to fit
9% OUTPUT
10% - MMAP: the fitted MMAP
11% - PHs: the fitted PH-distributions for each transition
12
13% compute two-step transition probabilities
14P2 = mmap_sigma2(mmap);
15
16% compute cross moments of order 1, 2 and 3
17M1 = mmap_cross_moment(mmap,1);
18M2 = mmap_cross_moment(mmap,2);
19M3 = mmap_cross_moment(mmap,3);
20
21% apply fitting algorithm
22[MMAP,PHs] = mmap_mixture_fit(P2, M1, M2, M3);
23
24end % end function