From the text:
g (n) - lower bound -- (Omega)

iff there exists positive constants c and no such that
f(n) > cg(n) for all n , n > no
(g(n) is a lower bound for f(n))
if f(n) > O(g(n)) and 
then asymptotically, we cannot have any improvement.
Improvement in constant possible.
Trivial lower bounds:
Max of set of n numbers
have to look at all inputs, n-1 comparisons :
f(n) is O(n) ;
(n)
n x n matrix multiplicaton: 2n2 inputs , n2 outputs
(n2)
but this is lower than the best known algorithm
Best known algorithm requires
f (n) = 0 (n2 +
Improvement possible or tighter lower bound exists. (See Chapter 3 for more details.)
Comparison-based algorithms - algorithms which work solely by making comparisons between elements; no arithmetic involving elements is permitted
A [1 : n]
p: permutation of {1, 2, . . . ., n}
The sorting problem calls for determining p, a permuation of the integers 1 to n, such that the n distinct values from S (the Set) stored in A[1:n] satisfy
A (p (1)) < A (p (2)) < . . .< A (p (n)) (ordering in terms of indices, not values) p(1) is the first in the permutation.
The ordered searching problem : A (1) < A (2) . . .< A (n)
again: restriction on class of algorithms for which lower bound applies - Linear Search (ordered array)
running time - longest path in tree
Binary Search
f (n) = O(log n)
If search terminates at interior nodes - success
. . . . . external (leaf) nodes - failure
How do we reason to determine lower bound?
consider any comparison tree to
search A [1 : n]
there must be n internal nodes corresponding to n possible successful outcomes.
k = maximum level of any internal node
then, number of internal nodes < 2k - 1 (proof by induction)
So best - optimal algorithm is binary search since it achieves this
Note that we did not look at any specific algorithm to detemine the lower bound, instead we considered information about the problem and considered what is the best we could do.
And, actually, we would want to consider the worst case of our best algorithm. Why? To see if it is the best possible.
Sort
number of external (leaf) nodes
= number of distinct permutations of {1, 2, . . ., n}
= n!
let k be max. level of any internal node in tree
T(n) = k
If max level of any internal node is k, then at most 2k external nodes By Stirling's approximation (see page 462)
= O(n log n)
see text
A similar phenomenon takes place when we use an oracle to establish a lower bound. Given some model of computation such as comparison trees, the oracle tells us the outcome of each comparison. To derive a good lower bound, the oracle tries its best to cause the algorithm to work as hard as it can. It does this by choosing as the outcome of the next test, the result that causes the most work to be required to determine the final answer. And by keeping track of the work done, a worse-case lower bound for the problem can be derived.
Two problems L1 and L2
T1 (n) = time to solve L1
T2 (n) = time to solve L2
L1 Definition: Let P1 and P2 be any two problems. We say P1 reduces to P2 in time p(n) if an instance of P1 can be converted into an instance of P2 and a solution of P1 can be obtained from a solution of P2
in time < p(n)
T1 (n1) = t12 + T2(n2) + t21
< p(n1) * T2 (n1)
T1 (n1) < p(n1) * T2 (n1)
L1: single source shortest path in undirected graphs
L2: single source shortest path in directed graphs
G-> = (V,E->)
c(u,v)-> = c(v,u)-> = c(u,v) for all (u,v)
call L2 (G->=(V,E->), c(E->), p)
// recover //
p = undirected version of p->
end
Claim: p shortest path in G <==> p-> shortest path in G-> not for any directed graph ... for ones considering in such a problem reduction
Proof: But, did conversion of l1 to l2 change anything? (is it possible that there exists some u -> q -> v in G-> such that the cost(q->) < cost (q)?)
No. Since we never introduced a path in l2 that does not exist in l1 In human words...why does this work? Cost of construction + recover = O(|V| + |E|)
T1 (n1) < poly (n1) * T2 (n2) number of edges in directed is at most twice what it was before
If T2(n) is also polynomial in n then we go one step further and T1(n1) is hence some poly. in n.
Comparison Trees: Searching/Sorting
Useful for modeling the way in which a large number of sorting and searching algorithms work,
i if x = A(i) for some i
0 otherwise
only comparison between elements - no arithmetic on keys.
Comparison Trees
Search
- O(n)

n! < 2k ; k = T(n) > log2(n!)
Hence any comparison-based sorting algorithm needs
(nlog n) time Selection
Oracles
From the text One of the proof techniques that is useful for obtaining lower bounds consists of making use of an oracle. The most famous oracle in history was called the Delphic oracle, located in Delphi, Greece. This oracle can still be found situated in the side of the hill embedded in some rocks. In olden times people would approach the oracle and ask it a question. After some period of time elapsed, the oracle would reply and a caretaker would interpret the oracle's answer
Polynomial Reductions
Here we discuss a very important technique that can be used to derive lower bounds. This technique calls for reducing the given problem to another problem for which the lower bound is already known.
L2 L1 reduces to L2
implies T1(n) < p(n) * T2(n)
Where p is some polynomial
proc L1 ( ) proc L2 ( )
call L2 ( )
end end
For each instance l1 of L1 construct an instance l2 of L2 such that a solution to l1 can be recovered from a solution to l2.
(size n2 since we may need to add some more structure to our problem in order to cast is as a problem in L2)
n2 = poly (n1) (i.e., must be bounded by a polynomial in n1 - otherwise, t12 non polynomial) what?

proc L1 (G = (V,E), c(E), p)
// G - undirected graph
// c - edge costs
// p - shortest path
// construction: instance of l1 making it an instance of l2
// make all directions go both ways
E->= { (u,v)->, (v,u)-> | (u,v)
(Notice that part that says undirected version of p->)
This is important...any directed to undirected does not work - it needs to maintain the information (we will see this in next lesson) ==>
suppose p is a shortest path in G. Then there exists a path p-> in G-> of same cost.
l1 and l2 are optimization problems. Suppose S1 is an optimal solution for l1. S->1 is a solution to l2 such that the value OPT(S->1) = OPT(S1)
<==
suppose p-> is shortest path in G->. Then the undirected version of p-> has same cost.
We have an undirected graph and want the shortest path. If we have something undirected, it can be interpreted as directed both ways. Since we have a way to find a solution for a shortest path when we have directions, what is the harm (or difference) in pretending that we do have directions? Pretend, Solve, stop Pretending. We did not change anything in the definition of the original graph.
T1(n1) < t12 + T2(n2) + t21 < t12 + t21 + poly(n) * T2(n1) < poly2 (n1) * T2(n1)