Package jline.api.cache
Class Cache_miss_rmf
java.lang.Object
jline.api.cache.Cache_miss_rmf
Refined mean-field (1/N-accurate) miss rates for RANDOM(m) caches.
Java port of the MATLAB cache_miss_rmf.m / Python
cache_miss_rmf. Mirrors the Cache_miss_fpi contract: the
popularity is recovered from the per-user per-item arrival rates (list-0
column), the mean-field fixed point is refined with its 1/N correction via
CacheRMF, and the per-item miss probability is the steady-state
occupancy of list 0.
Reference: N. Gast, "Expected Values Estimated via Mean-Field Approximation are 1/N-Accurate", Proc. ACM Meas. Anal. Comput. Syst., 2017.
-
Method Summary
Modifier and TypeMethodDescriptionstatic CacheMissFpiResultcache_miss_rmf(Matrix gamma, Matrix m, Matrix[] lambdaCache) Compute cache miss rates using the refined mean-field method.static CacheMissRmfTranResultcache_miss_rmf_tran(Matrix gamma, Matrix m, Matrix[] lambdaCache, double time, int nPoints, double[] xinit) Transient refined mean-field cache trajectory.
-
Method Details
-
cache_miss_rmf
Compute cache miss rates using the refined mean-field method.- Parameters:
gamma- item access factors (accepted for interface parity withCache_miss_fpi; used only for sizing fallbacks).m- cache capacity vector (h,).lambdaCache- per-user per-item per-list arrival rates:lambdaCache[v]is an (n x (h+1)) matrix; column 0 carries the request rates.- Returns:
CacheMissFpiResultwith global miss rate M, per-user MU, per-item MI, and per-item miss probabilities pi0.
-
cache_miss_rmf_tran
public static CacheMissRmfTranResult cache_miss_rmf_tran(Matrix gamma, Matrix m, Matrix[] lambdaCache, double time, int nPoints, double[] xinit) Transient refined mean-field cache trajectory. Integrates the same plain mean-field drift thatcache_miss_rmf(jline.util.matrix.Matrix, jline.util.matrix.Matrix, jline.util.matrix.Matrix[])drives to steady state over a finite window, from a supplied (or default) initial occupancy.Mirrors the MATLAB
cache_miss_rmf.mtspan path (order-0, no 1/N correction in the transient).- Parameters:
gamma- item access factors (accepted for interface parity; used only for sizing).m- cache capacity vector (h,).lambdaCache- per-user per-item per-list arrival rates.time- end time of the transient window (start is 0).nPoints- number of uniform grid points (>= 2).xinit- initial occupancy (modelDimension,), or null for the default first-m-in-list initial state.- Returns:
CacheMissRmfTranResultwith the time grid, per-item list-0 occupancy, per-user miss-rate trajectory, and full occupancy trajectory.
-