In many flowers , the gynoecium is the innermost whorl of structures and is surrounded by the androecium ( stamens ) and then by the perianth ( all the petals and sepals ) .
The gynoecium , the collective term for all the carpels , is the innermost whorl of the parts of a flower , and in many flowers the other parts ( sepals , petals , and stamens ) are attached to the receptacle beneath the gynoecium .