There are 40 animals at a petting zoo, all of which are goats or rabbits, and each animal is either an adult or a child. There are twice as many adult rabbits as adult goats, and three times as many child goats as adult goats. If there are an equal amount of adult rabbits as child rabbits, how many adult goats are there at the petting zoo?