Non-integrable differential equation and non-holonomic contraints 
From the constraint $v=a\dot{\phi}$ of a rolling disk over a plane, where $a$ is the radius of the disk we can derive these two equations:
we have two differential equations of constraint:
$dx=asin\theta d\phi$ 
$dy=-acos\theta d\phi$
Can you rigorously explain to me why can't I integrate these functions? Is it their non-integrability that makes these constraints non-holonomic?
 A: HINT:  Rewrite the first constraint as
$$
f \left[ dx +(- a \sin \theta) d\phi + (0) d\theta \right] = 0.
$$
where $f(x, \theta, \phi)$ is some unknown integrating function.  We want to know whether this can be written as
$$
dg = \frac{\partial g}{\partial x} dx + \frac{\partial g}{\partial \phi} d\phi+ \frac{\partial g}{\partial \theta} d\theta 
$$
Assuming that $g$ is a "nicely-behaved" function of the coordinates, its mixed partial derivatives are independent of the order of differentiation.  Using this fact, can you show that this implies $f = 0$?
To answer your second question:  there are different definitions of "non-holonomic" constraints used by different authors.  If you're following Goldstein, any constraint that cannot be written in the form $f(x_i) = 0$ is non-holonomic;  but there are also non-holonomic constraints that can only be written as equalities among the higher derivatives, or as inequalities.
A: In classical mechanics, holonomic constraints are relations between the position variables (and possibly time) that can be expressed in the following form: $g(y,t) = 0$
Nonholonomic constraints is when we can't express it in the form given above, and have to express it as $g(y,y',t) = 0$, where y' must be a variable to the constraint.
But, be careful, even though some constraints giving in the form $g(y,y',t) = 0$, it does not mean it can't be converted to a holonomic constraints of form $g(y,t)-$constant$ = 0$. These constraints that can be converted are actually holonomic constraints.
Thus the constraints that cannot be reduced to holonomic constraints by integration are nonholonomic constraint.
Now let $g(x,\theta,\phi,t) = dx-a\sin\theta d\phi = 0$ be our constraint.
If the differential constraint was exact the it should be in the form of
\begin{equation}\frac{dg}{dt} = \frac{\partial g}{\partial x}\frac{dx}{dt} + \frac{\partial g}{\partial \theta}\frac{d\theta}{dt} + \frac{\partial g}{\partial \phi}\frac{d\phi}{dt} +\frac{\partial g}{\partial t} =0\end{equation}
which is just
\begin{equation}\frac{dg}{dt} =0\end{equation}
which can be integrated into
\begin{equation}g(y,t)-constant = 0\end{equation}
which is a holonomic constraint
Showing that no integral exists
By dividing $g(x,\theta,\phi,t)$ by $dt$ and add $0\frac{d\theta}{dt}$ thus we get:
\begin{equation}\frac{dx}{dt}-a\sin\theta\frac{d\phi}{dt}+ 0\frac{d\theta}{dt} = 0\end{equation}
I order for it to be exact, we must be able to get
\begin{equation}\frac{\partial g}{\partial x} = 1,\frac{\partial g}{\partial \theta} = 0,\frac{\partial g}{\partial \phi} = -a\sin\theta\,\frac{\partial g}{\partial t} = 0\end{equation}
Suppose we want to try integrate to get g that matches the above partial derivatives
Method 1
\begin{equation}\frac{\partial g}{\partial x} = 1\end{equation}
integrate with respect to $x$,
\begin{equation}g = x + k_1(\theta,\phi,t)\end{equation}
differentiate with respect to $\theta$,
\begin{equation}\frac{\partial g}{\partial \theta} = k'_1(\theta,\phi,t) = 0 \end{equation}
integrate with respect to $\theta$, then sub in for $k_1$,
\begin{equation}g = x + \theta + k_2(\phi)\end{equation}
differentiate with respect to $\phi$,
\begin{equation}\frac{\partial g}{\partial \phi} = k'_2(\phi,t) = -a\sin\theta\end{equation}
integrate with respect to $\phi$, then sub in for $k_2$,
\begin{equation}g = x + \theta + a\cos\theta + k\end{equation}
But if we take $\frac{\partial g}{\partial \theta} = -a\sin\theta + 1\neq 0$ thus NOT integrable.
Method 2
Or we could simply do the exact check
\begin{equation} \left(\frac{\partial g}{\partial y_i}\right)_{y_j} = \left( \frac{\partial g}{\partial y_j} \right)_{y_i}\end{equation}
and immediately we can see that
\begin{equation} \left(\frac{\partial g}{\partial \phi}\right)_{\theta} = -a\cos\theta \neq 0 =\left( \frac{\partial g}{\partial \theta} \right)_\phi\end{equation}
which fails the exact check and thus NOT integrable.
