Our analysis goal is to end up with a gain equation in terms of vout/qin. In the process, we will gain some insight into how a charge amplifier deals with the problem of changing cable capacitance.
First, let's sum all the charge flows:
qin = qp + qc + qf
Because of the relationship q = CV, we can rewrite the above as:
qin = vinCp + vinCc + vfCf
qin = vin(Cp + Cc) + vfCf
We know, however, that vin = 0, because of the virtual short across the input terminals of the op amp (assume an ideal op amp). So the equation above simplifies to:
qin = vfCf
Rearranging, we have:
vf = qin/Cf
Again, because of the virtual short across the terminals of the op amp, we can say:
vout = vf = qin/Cf
Rearranging again, we have:
vout/qin = 1/Cf where units are mV/pC.