Euler formula for geometric modeling faces, holes
It is not entirely clear what you are asking, but the Euler formula is
V - E + F = 2 (1-g), where g is the number of holes (the genus).
Perhaps you also have cavities? Then look at this San José State exposition.