Open MichalisPanayides opened 4 years ago
UPDATE:
Markov Chain Tree Theorem: π_i = sum of the weight of all directed spanning trees rooted at that state
Initial Approach:
Attempt of getting π0,0 formula by completing the power:
Created modularised functions that return symbolic rate at state (0,0) and recursive ratios (nbs/other/closed_form_formula_of_pi/state_probabilities_example)
Adding rows: when having k rows at the model, the rate is equivalent to (one-row model)k:
Adding columns: more complicated - after some point terms get harder to predict
Attempt of getting π0,0 formula using combinatorics
Tried looking at the spanning trees problem from a combinatorics point of view
Turned Markov chain model into a graph theoretic model
Possible (λA) (λo) μ terms:
Managed to get coefficient for terms (λA)p1 (λo)p2 μp3 where one of p1, p2 or p3 was raised to a power of 1 or 0.
i.e. coefficients of the form [(λ A)2] [(λ o)3] [μ2] (where p1, p2,p3 > 1) could not be calculated
As problem gets bigger more cases of spanning trees appear and such cases were not found
Matrix-tree theorem: Laplacian of graph can be used to get the number of spanning trees at state i
Successful attempt of getting π0,0 formula using permutation algorithm
Translating the problem into a permutation problem:
The problem of finding all spanning trees becomes a problem of finding all possible permutations of an array with elements the characters "D", "R" and "L".
Arrays that represent valid spanning trees are the ones that don't end in "R" and don't have an "R" followed by an "L"
Note that such algorithm works for cases of parking_capacity = 1 (i.e. one additional row in the Markov chain model)
For parking_capacity > 1, apply (one-row model)parking_capacity described earlier
Based on that notion closed-form formula is calculate as:
Further investigate integer division in permutations formula ( // )
Generalise formula for general threshold T
Generalise formula for general number of servers C
Find recursive formula for πi based on π0,0 OR find formula for πi using spanning trees
This is exactly what I was hoping you'd write up @11michalis11. :+1: