I think you need to have all the males first, then the females.

In the "relative" section, you need to have the order

father, wife, males, females

..with the males\females section on descending order of ages.