Example TRIG.COMP.4 $h(x)=cos(x);g(x)=2x;f(x)=cos(2x)$.

Martin Flashman, Dec. 29, 2018. Created with GeoGebra

Notice how the arrows on the mapping diagrams are paired with the points on the graph of the functions.
You can move the point for $x$ on the mapping diagram to see how the function value for the function $ f(x) = \cos(2x)$ changes both on the diagram and on the graph.

Notice how the graph and mapping diagram visualize the fact that for the cosine function, $\cos(2x)$  has the same basic shape as $\cos(x)$, though its period has changed to  $\pi$.

Check the box to show points on the graph and arrows on the diagram for the function $ f(x) =\cos(2x)$.