Given:
Amplitude of cosine function, A=3.
Period, T=7π/4.
Midline, D=2.
The time period can be expressed as:

Put T=7π/4 to find the value of B.

The general cosine function can be expressed as,

Substitute B=8/7, A=3 and D=2 in above equation.

Therefore, the cosine function is,