Stated simply: a variable is live if it holds a value that may be needed in the future.
It is a "backwards may" analysis. The analysis is done in a backwards order, and the dataflow confluence operator is set union.

The set of live variables at line L2 is {b , c }, but the set of live variables at line L1 is
only {b } since variable c is updated in line 2. The value of variable a is never used,
so the variable is never live.

The dataflow equations used for a given basic block s and exiting block f in live variable analysis are:
The instate of a block is the set of variables that are live at the start of the block. Its outstate is the set of variables that are live at the end of it. The instate is the union of the outstates of the block's successors. The transfer function of a statement is applied by making the variables that are written dead, then making the variables that are read live.
// out: {}
b1: a = 3; b = 5; d = 4; if a > b then// in: {a,b,d} // out: {a,b} b2: c = a + b; d = 2;// in: {b,d} // out: {b,d} b3: endif c = 4; return b * d + c;// in:{} 
The outstate of b3 only contains b and d, since c has been written. The instate of b1 is the union of the outstates of b2 and b3. The definition of c in b2 can be removed, since c is not live immediately after the statement.
Solving the data flow equations starts with initializing all instates and outstates to the empty set. The work list is initialized by inserting the exit point (b3) in the work list (typical for backward flow). Its computed outstate differs from the previous one, so its predecessors b1 and b2 are inserted and the process continues. The progress is summarized in the table below.
processing  instate  old outstate  new outstate  work list 

b3  {}  {}  {b,d}  (b1,b2) 
b1  {b,d}  {}  {}  (b2) 
b2  {b,d}  {}  {a,b}  (b1) 
b1  {a,b,d}  {}  {} 
Note that b1 was entered in the list before b2, which forced processing b1 twice (b1 was reentered as predecessor of b2). Inserting b2 before b1 would have allowed earlier completion.
Initializing with the empty set is an optimistic initialization: all variables start out as dead. Note that the outstates cannot shrink from one iteration to the next, although the outstate can be smaller that the instate. This can be seen from the fact that after the first iteration the outstate can only change by a change of the instate. Since the instate starts as the empty set, it can only grow in further iterations.
Recently as of 2006, various program analyses such as live variable analysis have been solved using Datalog. The Datalog specifications for such analyses are generally an order of magnitude shorter than their imperative counterparts (e.g. iterative analysis), and are at least as efficient.