<s>[INST] some special points of $A\sin(\omega x+\varphi)+B$ consider
$$f(x)=A\sin(\omega x+\phi)+B$$
$A>0,\omega>0,|\phi|<\frac{\pi}2$
if we have $f(1)=2,f(2)=\frac12,f(3)=-1,f(4)=2$
how to directly find one solution?
My way is to notice $(2,1/2)$ is the mid point of $(1,2)$ and $(3,-1)$ , guess $B=\frac 12$, then get $\omega=\frac{2\pi}3$, then get $\phi=-\frac{\pi}3$,finally
$$
f(x)=\frac{1}{2}+\sqrt{3} \sin \left(\frac{2 \pi  }{3}x-\frac{\pi }{3}\right)
$$
But if without noticing the mid point by accident, how to discovery it?
 [/INST] Note $f(1)=f(4)$, or
$$\sin(4\omega +\varphi)-\sin(\omega +\varphi)=2\cos\frac{5\omega+2\phi}2\sin\frac{3\omega}2=0$$
which yields $\sin\frac{3\omega}2=0$, or
$$\omega = \frac{2\pi}3$$
 Then, 
$$f(1) = 2       =A\sin \left(\frac{2\pi}3 + \phi\right) + B\tag 1$$
$$f(2) = \frac12 =A\sin \left(\frac{4\pi}3 + \phi\right) + B\tag 2$$
Take (2) - (1) to get $-\frac32 = A \sin\phi$ and plug it into $f(3) = -1 =A\sin\phi + B$ to get
$$B=\frac12$$
Then, take (2) + (1) to get $ A\cos\phi = \frac{\sqrt3}2$. Along with  $-\frac32 = A \sin\phi$ to have $\tan\phi = -\sqrt3$, which yields
$$\phi = -\frac\pi 3,\>\>\>\>\>A=\sqrt3$$
</s>