I have the question "resolve the following forces into their vertical and horizontal components"

The solutions show that the answer should be:

I know that trigonometry needs to be used but I am unsure as to how the answer is achieved.
I have the question "resolve the following forces into their vertical and horizontal components"

The solutions show that the answer should be:

I know that trigonometry needs to be used but I am unsure as to how the answer is achieved.
If we denote that force by $F$, then its $x$ and $y$ components are $F_x=4\cos 45^\circ=2\sqrt{2} N$ and likewise, $F_y=2\sqrt{2}N$.
You can get the horizontal component as: $F_{||}=F\cos45=4{\sqrt2\over2}$N
You can get the vertical component as: $F_{\perp}=F\sin45=4{\sqrt2\over2}$N
You have
$$cos(45°)=\frac{F_h}{F}$$
and
$$F_h=F.\cos(45°)=F\frac{\sqrt{2}}{2}$$
$$=4 \times 0.707=2.828 N.$$
To you to find $F_v$.
The horizontal force $F_H$ is given as:
$\sin(45) = F_H / 4$ and so $F_H = 4 \times \sin(45) = 2.828...$.
Similarly for the vertical force:
$F_V / 4 = \cos(45)$ and so $F_V = 4 \times \cos(45) = 2.828...$