Use the function f(t) = a·sin(bx+c)+d since we start at the minimum:
Amplitude: |a| --> (40-4)/2=18
Period: 2π/|b| --> 2π/|b| = 4 --> b=π/2
Phase/Horizontal Shift: -c/b = 0 --> -c/(π/2) = 1 --> c = -π/2
Midline: y=d=(40+4)/2=22
Final function is f(t) = 18sin(πx/2+π/2)+22
After t=2 minutes:
f(2) = 18sin(2π/2+π/2)+22 = 18sin(3π/2)+22 = 18(-1)+22 = -18+22 = 4
Hope this helped!