Found a common bug in LateX that is so persistent that even the Fedora 9 /CentOS5.2 shipped latex still has this problem. I have not checked if Fedora 10 fixes this already.
Simply put it, to get a correct figure number,
type \caption first and then followed by \label. (in other words,
Label should come Last).
The figure number is wrong if you put \label before \caption.
LateX claims to be a high quality scientific software that I don't
it should fail on such trivial thing.
I noticed the problem but was not able to solve it.
Only
http://www.terminally-incoherent.com...igure-numbers/
tells me what to do. But I guess since linux distros ship LateX, can someone
out there please fix this once and for all. Don't make science harder than it already is.