Thank you, crutschow.
I understand what you are saying, I've seen this equation before. But, I am interested in simulating this circuit and measuring power it consumes. How do you propose to do this? In the first circuit (NAND, one with CMOS inverter) I did it by measuring the current of the supply - I figured: all that is consumed must go through the supply. Is this correct assumption, or am I wrong? Also, all that is consumed must go through ground, so where to put ground in the second circuit (AND)? For example, to connect a capacitive load of 1pF and than to measure current that goes through it? I think that the dissipated power we are talking about (C*V*V*f) would taken into account here.