Ming's profileMing's Mathematicalizati...PhotosBlogListsMore Tools Help

Blog


    11/18/2006

    Transient State Solution for n state Birth-Death Process

    I've been trying to figure out a way to find the transient state solutions for n state Birth-Death Process by solving a system of matrix equations instead of looking at each differential equaions one by one.  Let P(t) be the transient state distribution matrix at time t, I be the identity matrix, Q be the rate of change matrix, and A_i's be the coefficient matrices for each e^r_i where r_i is the nonzero eigenvalues of Q.  Then first P(0) = I, P'(0) = Q, and Q has 3 properties: first the main diagonal of Q has negative entries; second, everything off diagonal is positive; third, the sum of entries from each row is zero.
     
    1. Q is a matrix of real entries, thus the characteristic equation of det(Q - rI) always has solution in the complex field.
    2. That Q has an eigenvalue of zero depends on if such Brith-Death Process has a steady state(just proposition).
    3. Q will not have positive eigenvalues (not yet proven)
     
    Hence consider the case when Q has an eigenvalues of zero, and let it be r_0, that is, r_0=0
    Category one:  Q has n distinct real eigenvalues. Let R = {r_0, r_1, ..., r_(n-1)}, then r_i != (not equal to) r_j if i != j.
     
    So P(t) = A_0 + A_1 * e^(r_1*t) + A_2 * e^(r_2*t) + ... + A_(n-1) * e^((n-1)*t)
     
    case one: For a 2 state Birth-Death Process, we will have the following equations:
    I   =  A_0 + A_1
    Q  =            A_1 * r_1
     
    where the equations can be written as the vector equation:
    [I, Q]^T (the transpose of the row vector) =   | 1   1   | * [A_0, A_1]^T
                                                                       | 0   r_1|
     
    which is a linear transformation from [A_0, A_1] to [I, Q], (since all of them are 2*2 matrices) using the transform matrix:
    |1  1   |
    |0  r_1|
     
    is it possible? yes, similar to the partition of a matrix so that one can do the matrix multiplication easier and faster.  the multiplication between each entry in the transform matrix and the new vector [A_0, A_1]^T is defined, because it's just the scalar multiplication of a matrix.
     
    then A_0 = I - [1/r_1] * Q; A_1 = [1/r_1] * Q
     
    case two: for a 3 state Birth-Death Process, they satisfy the following equations:
    I        = A_0 + A_1                       +  A_2
    Q       =           A_1 * r_1              +  A_2 * r_2
    Q^2   =           A_1* (r_1)^2         + A_2 * (r_2)^2
     
    So the transform matrix is 
    | 1   1              1         |
    | 0   r_1           r_2      |
    | 0   (r_1)^2    (r_2)^2|
     
    by getting an inverse of this matrix, we can get
    A_0 = I - [1/(r_1*r_2)] * Q^2 + [(r_1 + r_2)/(r_1*r_2)] * Q
    A_1 = [1/(r_1*(r_1-r_2))] * (Q^2 - r_2 * Q)
    A_2 = [1/(r_2*(r_2-r_1))] * (Q^2 - r_1 * Q)
     
    case three: for a 4 state Birth-Death Process, the matrices satisfy the following equations:
    I        =  A_0 + A_1                         +  A_2                   + A_3
    Q       =           A_1 * r_1                 +  A_2 * r_2           + A_3 * r_3
    Q^2   =           A_1 * (r_1)^2           + A_2 * (r_2)^2     + A_3 * (r_3)^2
    Q^3   =           A_1 * (r_1)^3           + A_2 * (r_2)^3     + A_3 * (r_3)^3
     
    So then transform matrix is :
    | 1   1            1            1          |
    | 0   r_1         r_2         r_3       |
    | 0   (r_1)^2  (r_2)^2  (r_3)^2  |
    | 0   (r_1)^3  (r_2)^3  (r_3)^3  |
     
    Similar process of solving for inverse matrix, we can get:
    A_0  = I - [1/(r_1*r_2*r_3)] * Q^3 + [(r_1+r_2+r_3)/(r_1*r_2*r_3)] * Q^2 - [(r_1*r_2 + r_2*r_3 + r_3*r_1)/(r_1*r_2*r_3)] * Q
    A_1 = [1/(r_1*(r_1-r_2)*(r_1-r_3))] * (Q^3 - (r_2+r_3) * Q^2 + r_2*r_3 * Q)
    A_2 = [1/(r_2*(r_2-r_1)*(r_2-r_3))] * (Q^3 - (r_1+r_3) * Q^2 + r_1*r_3 * Q)
    A_3 = [1/(r_3*(r_3-r_1)*(r_3-r_2))] * (Q^3 - (r_1+r_2) * Q^2 + r_1*r_2 * Q)
     
    Remark: as one can see, there's a pattern in the solutions for the A_i's.
     
    case four: for a 5 state Birth-Death Process, the matrices satisfy the following equations:
    I        =  A_0 + A_1                         +  A_2                   + A_3                   +  A_4     
    Q       =           A_1 * r_1                 +  A_2 * r_2           + A_3 * r_3          +   A_4 * r_4
    Q^2   =           A_1 * (r_1)^2          + A_2 * (r_2)^2      + A_3 * (r_3)^2    +  A_4 * (r_4)^2
    Q^3   =           A_1 * (r_1)^3          + A_2 * (r_2)^3      + A_3 * (r_3)^3    +  A_4 * (r_4)^3
    Q^4   =           A_1 * (r_1)^4          + A_2 * (r_2)^4      + A_3 * (r_3)^4    +  A_4 * (r_4)^4
     
    thus the transform matrix is:
    | 1   1            1            1            1        |
    | 0   r_1         r_2         r_3        r_4      |
    | 0   (r_1)^2  (r_2)^2  (r_3)^2  (r_4)^2| 
    | 0   (r_1)^3  (r_2)^3  (r_3)^3  (r_4)^3| 
    | 0   (r_1)^4  (r_2)^4  (r_3)^4  (r_4)^4|
     
    similarly the solutions are:
    A_0  = I - [1/(r_1*r_2*r_3*r_4)] * Q^4 + [(r_1+r_2+r_3+r_4)/(r_1*r_2*r_3*r_4)] * Q^3 - [(r_1*r_2 + r_2*r_3 + r_1*r_3*r_1*r_4+r_2*r_4+r_3*r_4)/(r_1*r_2*r_3*r_4)] * Q^2 + [(r_1*r_2*r_3+r_1*r_2*r_4+r_1*r_3*r_4+r_2*r_3*r_4)/(r_1*r_2*r_3*r_4)] * Q
    A_1 = [1/(r_1*(r_1-r_2)*(r_1-r_3)*(r_1-r_4)] * (Q^4 - (r_2+r_3+r_4) * Q^3 + (r_2*r_3+r_2*r_4+r_3*r_4) * Q^2 - r_2*r_3*r_4 * Q)
    A_2 = [1/(r_2*(r_2-r_1)*(r_2-r_3)*(r_2-r_4)] * (Q^4 - (r_1+r_3+r_4) * Q^3 + (r_1*r_3+r_1*r_4+r_3*r_4) * Q^2 - r_1*r_3*r_4 * Q)
    A_3 = [1/(r_3*(r_3-r_1)*(r_3-r_2)*(r_3-r_4)] * (Q^4 - (r_1+r_2+r_4) * Q^3 + (r_1*r_2+r_1*r_4+r_2*r_4) * Q^2 - r_1*r_2*r_4 * Q)
    A_4 = [1/(r_4*(r_4-r_1)*(r_4-r_2)*(r_4-r_1)] * (Q^4 - (r_1+r_2+r_3) * Q^3 + (r_1*r_2+r_1*r_3+r_2*r_3) * Q^2 - r_1*r_2*r_3 * Q)
     
    Now we can conclude that:
    for a n state Birth-Death process:
    A_0 = I - [1/(r_*r_2*r_3*...*r_(n-1))] * Q^(n-1) + [(r_1+r_2+r_3+...+r_(n-1))/(r_*r_2*r_3*...*r_(n-1))] * Q^(n-2) - [(r_1*r_2 + r_1*r_3 +...+r_1*r_(n-1) +r_2*r_3 +r_2*r_4 + ... +r_2*r_(n-1) +r_3*r_4 +r_3*r_5 + ... + r_3*r_(n-1) + ... + r_(n-2)*r_(n-1))/(r_*r_2*r_3*...*r_(n-1))] * Q^(n-3) + [(r_1*r_2*r_3 + r_1*r_2*r_4 + ... r_1*r_2*r_(n-1) + ... + r_(n-3)*r_(n-2)*r_(n-1))/(r_*r_2*r_3*...*r_(n-1))] * Q^(n-4) - ... (-1)^(n-1) * (r_1*r_2*...*r_(n-1)) * Q
     
    for i != 0,
    A_i = [1/(r_i*(r_i-r_1)*...*(r_i-r_(i-1))*(r_i-r_(i+1))*..*(r_i-r(n-1)))] * (Q^(n-1) - (r_1 + r_2 + ... + r_(i-1) + r_(i+1) + .. + r_(n-1)) * Q^(n-2) + ... (-1)^n * r_1*r_2*...*r_(i-1)*r_(i+1)*...*r_(n-1) * Q)
     
    Category two: for there are repeating eigenvalues, the transicent state equations can be written as:
    Case 1: r_0 = 0 being the only eigenvalue, so the multiplicity is n
    So P(t) = A_0 + A_1 * t + A_2 * t^2 + ... + A_(n-1) * t^(n-1)
    I               =  A_0 * 0!
    Q              =  A_1 * 1!
    Q^2          =  A_2 * 2!
    ...
    Q^(n-1)    =  A_(n-1) * (n-1)!
     
    thus P(t) = I + Q*t + [1/2] * (Q*t) ^2 + [1/3!] * (Q*t)3 + ... + [1/(n-1)!] * (Q*t) ^ (n-1)
     
    case 2: suppose there are more than 2 eigenvalues.  Let r_0, r_1, r_2, ..., r_k be k disntinct eigenvalues with
    multiplicity m_0, m_1, m_2, ..., m_k. with the following properties: m_i >= 1 for 0 <= i <= k; second,
    m_0 + m_1 + m_2 + ... + m_k = n.  and r_0 = 0 is known.
     
    then:P(t)= A_0 + A_1 * t + A_2 * t^2 + ... + A_(m_0-1) * t^(m_0-1) + A_(m_0) * e^(r_1*t) + A_(m_0+1) * t * e^(r_1*t) + ... + A_(m_0+m_1-1) * t^(m_1-1) * e^(r_1*t) + A_(m_0+m_1) * e^(r_2*t) + A_(m_0+ m_2 + 1) * t * e^(r_2*t) + ... + A_(m_0 + m_1 + m_2 + ... + m_(k-1)) * e^(r_k*t) + A_(m_0+m_1+...+m_(k-1) + 1) * t * e^(r_k*t) + ... + A_(m_0+m_1 + ... + m_(k-1) + m_k - 1) * t^(m_k - 1) * e^(r_k*t)
     
    I       =       A_0 + A_(m_0) + A_(m_0+m_1) + ... + A_(m_0+m_1+...+m_(k-1))
    Q      =      A_1 + r_1*A_(m_0) + A_(m_0+1) ....
     
    Category three: with complex eigenvalues, (to be continued)
     
    I will try to write up a clear version of the differential equations for the one in category two
     
    Btw, don't do math on weekend :)
     
    11/15/2006

    Sucky Windows Live Messenger

    Got up early to work on homework, it's about topology btw, connectedness :) well trying to kinda pop on and off on msn so that I  can talk while taking breaks from homework... however it turned out to be the case that my messeges just couldn't get through the whole msn network onto the other end of this lil earth.  ... it does indeed sucks... this is some real disappointment .. well anyway, gotta get back to my homework.. coz it's due today haha...and nothing real interesting has happened these days........ normal and daily rountines.. except that Mr. No No just got a 10 hours midterm on Monday, which forced me to stayed there till 4:30am so as to drive him back home and my yummy korean pizza, I gave it to him since he hasn't eaten anything from 2pm that afternoon.  His prof. has to really reconsider his teaching style.....there are like 27 problems on that midterm and each of them has at least 2 to 3 subproblems... frankly they're only engineering students, they're not supposed to know too much about linear algebra mathematically especially at the graduate level, especially those concepts like vector space, jordan forms, linear transformation.  I guess they still don't know what their professor's talking about in class ... poor kids...poor graduate student.. they do have 24 hours everyday, but it seems they spend all of them working their linear algebra homework.... /shrug that's some math love
    11/3/2006

    Car Accident, Reckless Driver..

    Although it wasn't me who crashed into some van's fat butt,  such reckless driving almost got me invovled. The mercedes was changing lane too fast, ignoring the van in front that was stopping, wanting to cut into my lane, and suddenly. boooooom......the head light was high up in the air spinning. ok the exact situation was.... the mercedes actually was at least 3 cars of space ahead of me, (enough space to change lane without rushing); second, there's a red light ahead, so most of us were preparing to stop; and it still ignored that van in front of him (or her) and crashed into its fat butt....and... it tiltingly stopped wit its head taking part of my lane, forcing me to make a sharp steering to avoid hitting into its prestigious Benz's butt, and avoided an interlinked crash with cars behind me...quite scary, coz I  was thinking he could make the lane change rather smoothly without hitting somebody's van.  and the noise of the crash was a bit surprising, in fact .. watching the head light spinning in the air was .. a bit sarcastically fun...I hope I  wasn't being satiric.  I'm sorry for that Mercedes, and the family (well most of the time there's only one in a big big gigantic van) inside that van.  it's a rear collision, so the Mercedes is gonna take on the full responsibility, however having your car hit isn't quite a fun experience, for which I  can assure.
     
    gosh.. too many freaks in LA.....
    11/2/2006

    Two Down, One More to Go

    Prof. Krinik had small surgery, as far as the size of organ where the surgery is performed is concerned, on one of his eyes.  So the midterm for his Queueing Theory class was postponed for a week. Insetad of having it on this Thursday, it will be on next Thursday with a proposed review section on this Friday afternoon.
     
    Done writing up review material for Topology and Analysis.  The topology midterm was easier than I thought, too lil proofs, too much exampls.  whereas the analysis one was quite fun :) using the axiom of choice in one of those practical problems is somehow unexpected.    and I have to read some more theories of the calculus we did back in undergrad. I was too slow connecting this bounded differentiability with mean value theorem, and uniform continuity....hopefully... my prof. will be more concentrated on measure theory instead... >.<
     
     
    Went to KTV on Halloween, well I've only spent 2 hours there with the other 5 hours in class listening to the renown result of our beloved M/M/1 queue.  So far, so good.  Just want a job >.< with high pay and low work load, ... /grin
     
    Oh, David, I kinda miss ya >.>