How to calculate the efficiency from a $p$-$v$ diagram? 
Question: Calculate the efficiency of the real and ideal cycles.
The process 1-2 is polytropic, 2-3 is isochoric, 3-4 is polytropic as well, and 4-1 completes the cycle with another isochoric process.
My attempt: I know that to calculate the efficiency of a cycle we must know the work done as output and the heat supplied to the system. As such, the efficiency will be the ratio of these two:
$$\eta = \frac{w_{out}}{q_{in}}$$
From this diagram, I am able to calculate $w_{out}$ but I don't see how $q_{in}$ can be determined.
I originally just thought it to be equal to the work done from process 1-2, but I don't see think that is correct at all.
Would the heat in be through the isochoric process 4-1?
I'm not even sure if the heat in can be calculated straight from the p-v diagram. 
Any help regarding how to determine $q_{in}$ would be greatly appreciated.
Edit: Can assume a working substance is undergoing this cycle. E.g. air
 A: See if you can show that, for a polytropic expansion or compression, $$Q=m\left[C_V-\frac{R}{(n-1)}\right]\Delta T$$where m is the number of moles.  So you can get the heat for the polytropic expansion and compression in your process by knowing the temperatures and pressures at the two end points (using the polytropic equation in conjunction with the ideal gas law).  So, the first step in your calculation should be to get the temperatures and pressures at the four corners of your cycle.  
Of course, for the constant volume changes, $Q=mC_v\Delta T$.  
So you can get the heat for all four legs of your cycle.
A: The $P$-$V$ diagram, in isolation, is only enough to calculate the work done by a cycle. To calculate the efficiency you need to be able to measure the heat flux into and out of the system. Doing that requires something equivalent to the $T$-$S$ (temperature-entropy) diagram. This is not usually stated explicitly because entropy is not easy to measure, so it is normally reconstructed from the $P$-$V$ diagram using an equation of state for the working substance of the engine (e.g. $PV=NkT$). The equation of state gives you $T(V)$ or $T(P)$ (i.e. $T$ as a function of...), when those are combined with some expression for the heat capacity (usually the heat capacity at constant volume, $C_V$) it is possible for the calculation of heat flow in each step of the cycle. 
For an ideal monatomic gas the heat capacity is given by:
$$C_V = \frac{3}{2} N k.$$
That $3$ in the numerator comes from the number of ways in which the gas atoms can move through space (3 dimensions). It literally comes from the equipartition theorem that any term in the description of the energy of the atoms that make up a substance that is quadratic in position or momentum contributes $k/2$ per atom to $C_V$. So, for a gas of diatomic molecules at low temperatures we get two rotational degrees of freedom, giving $C_V=\frac{5}{2}Nk$. As the temperatures go up the molecules can start vibrating, too, increasing $C_V$ to approximately $\frac{7}{2} Nk$ (1 each for the atoms' vibrational kinetic and potential energies) until the atoms fully disassociate and it drops back down to $\frac{6}{2} Nk = \frac{3}{2} N_{\mathrm{new}}k$.
Bottom line: you need to use the properties of your working substance and the processes you subjected it to (polytropic and isochoric/isometric) to deduce the heat flow during each step.
