Package jline.lib.m3a
Class M3aUtils
java.lang.Object
jline.lib.m3a.M3aUtils
Utility functions for M3A (Markovian Arrival Process with 3-moment Approximation) compression.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceFunctional interface for constraint functions used by COBYLA.static interfaceFunctional interface for objective functions used by COBYLA. -
Method Summary
Modifier and TypeMethodDescriptionstatic Double[]computeAutocorrelation(MatrixCell MMAP, int maxLag) Computes the autocorrelation function of an MMAP up to the specified lag.static doublecomputeCoeffVar(MatrixCell MMAP) Computes the coefficient of variation of an MMAP.static doublecomputeIDC(MatrixCell MMAP, double timeWindow) Computes the index of dispersion for counts (IDC) of an MMAP.static doublecomputeKLDivergence(MatrixCell MMAP1, MatrixCell MMAP2) static doublecomputeKLDivergence(MatrixCell MMAP1, MatrixCell MMAP2, int numSamples) static doublecomputeKLDivergence(MatrixCell MMAP1, MatrixCell MMAP2, int numSamples, int seed) Computes the Kullback-Leibler divergence between two MMAPs.static Double[]computeMoments(MatrixCell MMAP, int n) Computes the first n moments of an MMAP.static doublecomputeSpectralGap(MatrixCell MMAP) Computes the spectral gap of an MMAP generator matrix.static Double[]optimizeParameters(Double[] initialParams, M3aUtils.ObjectiveFunction objectiveFunction, M3aUtils.ConstraintFunction[] constraints) static Double[]optimizeParameters(Double[] initialParams, M3aUtils.ObjectiveFunction objectiveFunction, M3aUtils.ConstraintFunction[] constraints, double tolerance) Optimizes MMAP parameters using COBYLA optimization.static booleanvalidateMMAP(MatrixCell MMAP) Validates that a matrix represents a valid MMAP.
-
Method Details
-
computeAutocorrelation
Computes the autocorrelation function of an MMAP up to the specified lag. -
computeIDC
Computes the index of dispersion for counts (IDC) of an MMAP. -
computeCoeffVar
Computes the coefficient of variation of an MMAP. -
computeMoments
Computes the first n moments of an MMAP. -
computeSpectralGap
Computes the spectral gap of an MMAP generator matrix. -
optimizeParameters
public static Double[] optimizeParameters(Double[] initialParams, M3aUtils.ObjectiveFunction objectiveFunction, M3aUtils.ConstraintFunction[] constraints) -
optimizeParameters
public static Double[] optimizeParameters(Double[] initialParams, M3aUtils.ObjectiveFunction objectiveFunction, M3aUtils.ConstraintFunction[] constraints, double tolerance) Optimizes MMAP parameters using COBYLA optimization. -
computeKLDivergence
-
computeKLDivergence
-
computeKLDivergence
public static double computeKLDivergence(MatrixCell MMAP1, MatrixCell MMAP2, int numSamples, int seed) Computes the Kullback-Leibler divergence between two MMAPs. -
validateMMAP
Validates that a matrix represents a valid MMAP.
-