Question about normal force acting on a mass on an inclined plane 
Suppose we are given the free-body diagram above, with a mass on an incline at an angle $\theta$. If my coordinate axes are taken to be the regular $x-y$ plane rotated an angle of $\theta$ (i.e. the x axis is parallel to the direction of $mg \sin \theta$ and the $y$ axis is parallel to $mg \cos \theta$), then if there is no vertical motion, $N = mg \cos \theta$.
Now suppose I take my coordinate axes to be the $x-y$ plane but NOT rotated by any angle (i.e. the $x$ axis is parallel to the base of the triangle and the $y$ axis is parallel to the adjacent side), then if I want to resolve my weight $mg$ in the direction of $N$, wouldn't I need to make it $\frac{mg}{\cos \theta}$? (since in this case I would have to find the force whose vertical component is $mg$) If this is the case, no vertical motion would imply that $N = \frac{mg}{\cos \theta}$.
Does this mean that $N$ depends on my choice of coordinate axes? I might be making a mistake, but I'd appreciate if someone could point out the mistake in my logic.
 A: Changing coordinate axis is not a physical change. The net value of normal reaction remains same.
If coordinate axis are chosen to be parallel to the incline -
Now as the block is at rest i am assuming it is due to friction. Let's say that the friction  force is $f$
X-direction :$ \ \ N=mg \text { cos }\theta$
 Y- direction :$ \ \ mg \text { sin } \theta=f$

Squaring and adding above two we get : 
$$N^2+f^2=mg^2$$
Rearranging
$$N=\sqrt{mg^2-f^2}$$
Now when coordinate axes are parallel to the base of wedge
Y direction:
$N \text { cos } \theta+f \text { sin }\theta=mg$
Squaring it :
$$(N \text { cos }\theta)^2+(f \text { sin }\theta)^2 + 2Nf\text { sin }\theta \text { cos }\theta=mg^2$$
X direction :$N \text { sin }\theta-f \text { cos }\theta=0$
Squaring it :
$$(N \text { sin }\theta)^2+(f \text { cos }\theta)^2 -2Nf\text { sin }\theta \text { cos }\theta=0$$
Adding the two squaring term we get :
$$N^2+f^2=mg^2$$
$$ \text {or} $$
$$N=\sqrt{mg^2-f^2}$$
Hence proved.
A: The normal force $\vec{N}$ is a vector, as indicated by my use of notation. As such, the expression does depend on the coordinate frame. However, the actual force is independent of the frame of reference.

*

*In your first case, where you consider your $x-y$  axis to be parallel with the incline, the vector $\vec{N}$ has only a component in the $y$ direction. This means that

$$\vec{N} = 0\cdot \hat{x} + mg \cos \theta \hat{y}, $$
where the hatted vectors are unit vectors in the respective directions. The magnitude of $\vec{N}$ is, as you pointed out, $|\vec{N}| = mg \cos \theta$.


*Now we consider the second case, where the $x-y$ axis is parallel to the ground. In this case, the normal force has to be decomposed in both the $x$ and $y$ directions, but now both components are non-zero. In this new coordinate system we call the vector $\vec{N}'=R(-\theta)\vec{N}$ to indicate that its algebraic expression looks differently, even though physically they are the same thing. Here $R(-\theta)$ (the minus sign is because the second coordinate system is rotated clockwise with respect to the first one) is a rotation matrix, which yields the following expression for $\vec{N}'$
$$\vec{N}'= -|\vec{N}| \sin\theta \, \hat{x} + |\vec{N}| \cos\theta \,\hat{y}\\
=-mg \cos \theta \sin \theta \,\hat{x} + mg \cos^2\theta \,\hat{y}.$$
You can see now that computing the magnitude of $\vec{N}'$ in this reference frame would yield the same result
$$|\vec{N}'|= \sqrt{m^2 g^2 \cos^2 \theta (\cos^2 \theta +\sin^2\theta)}=\sqrt{m^2 g^2 \cos^2 \theta }=m g \cos \theta.$$
I hope that helps.
Note:
You don't need matrices to do this. You can calculate the $x$ and $y$ components by pure geometry. I included the matrix to showcase a different point of view, but it is not essential. The point is that vectors look differently in different coordinate systems, despite being fundamentally the same object.
