These rules enable you claim a child as a dependent.
Qualifying Children
To be claimed as a qualifying child, the person must meet four criteria:
Relationship — the person must be your child, step child, adopted child, foster child, brother or sister, or a descendant of one of these (for example, a grandchild or nephew).
Residence — for more than half the year, the person must have the same residence as you do.
Age — the person must be
* under age 19 at the end of the year, or
* under age 24 and a be a full-time student for at least five months out of the year, or
* any age and totally and permanently disabled.
Support — the person did not provide more than half of his or her own support during the year.
http://taxes.about.com/od/dependents/a/Dependents_2.htm