Why is the scalar field Lorentz invariant? I have the following solution for the KG equation (real scalar field):
$$\phi (x) = \int \frac{d^3p}{(2\pi)^3\sqrt{2E_p}} [a_p e^{-ipx}+ a_p^\dagger e^{(ipx)}]$$
In my course we have rewritten it as
$$\phi (x) = \int \frac{d^3p}{(2\pi)^3 2E_p} [\alpha(p) e^{-ipx}+ \alpha(p)^\dagger e^{(ipx)}], $$
where $\alpha(p) = \sqrt{2E_p}$.
So, the effect of a Lorentz transformation is $\phi(x) \rightarrow \phi (\Lambda x)$, equivalently $\alpha(p) \rightarrow \alpha(\Lambda p)$. I don't understand how does that implies that the field is Lorentz invariant. A Lorentz invariant field would be $\phi'(x') = \phi(x)$, not $\phi'(x') = \phi(\Lambda x)$  for me.
 A: In my opinion, expressions like $\phi'(x')=\phi(x)$ are intrinsically a bit confusing. The idea is that we initially assign a point some coordinates $x$, and the value of the field at that point is given by a function $\phi:x\mapsto \phi(x)$. After performing a transformation, we will have a new function $\phi'$ and (in the case of a passive transformation) new coordinates $x'$ for each point.
Passive Transformations
If we change the way we label our points - that is, if we perform a coordinate transformation $x \mapsto x'$ - then obviously we will need a new function $\phi'$ to tell us the value of the field at a particular point. If the field is a scalar field, then the new function evaluated at the new coordinates should give us the same number as the old function evaluated at the old coordinates (because after all, we're talking about the same point with different labels), and so we have that $\phi'(x')=\phi(x)$.
Let $R$ be a rotation matrix which rotates our basis vectors by $\pi/2$ about the $z$-axis (so $R \hat x = \hat y, R \hat y = -\hat x$).  If the original coordinates of our point are $x=(0,1)$, then the transformed coordinates will be $(1,0)$; similarly, $x=(1,0)$ is transformed to $x'=(0,-1)$.  Convince yourself that this means$^\dagger$ that $x' = R^{-1}x$. Therefore, we would have in particular that $\phi'(R^{-1} x) = \phi(x) \iff \phi'(x) = \phi(R x)$, which extends to Lorentz transformations when we replace $R$ by $\Lambda$.
Active Transformations
If rather than changing our coordinates we literally transform the field itself - say, by rotating or boosting the laboratory - then we will also need a new function to tell us the value of the field at a given point.  If we rotate the field by $\pi/2$ about the $\hat z$-axis, then the value of the transformed field at the point $(1,0)$ is equal to the value of the old field at the point $(0,1)$. Convince yourself that this means that $\phi'(x) = \phi(R^{-1} x)$.

$^\dagger$The fact that the basis vectors transform via $R$ and the coordinates transform via $R^{-1}$ is why things with upstairs indices - such as the coordinate functions - are sometimes called contravariant; we should be careful to note that the coordinates generically do not constitute a vector, though.
A: The term "Lorentz invariant" almost always actually means "Lorentz covariant", where "covariant" is understood as meaning certain things for certain types of objects (tensors). For example, if $\phi (x )$ is a Lorentz scalar, then if you change coordinates from $x$ to $y(x)$, you will find $\phi (y(x))=\phi (x)$, i.e. the change is purely in the coordinates. The idea you can have for this is a temperature function, assigning a temperature to each point in the room. The temperature at a location $\vec x$ is what it is, regardless if one person uses a coordinate system where $\vec x = (1,2,3)$ and another uses a coordinate system where $\vec x = (0,0,0)$.
A Lorentz vector $A^\mu (x)$ would transform as $T^\mu\,_{\nu} A^\nu (y(x)) = A(x)$, where $T^\mu\,_{\nu}$ is the transformation matrix defined by $T^\mu\,_{\nu}=\partial y^\mu/\partial x^\nu$.
