Fourier Arbitrary-Phase Sinusoid Series A Fourier Cosine Series uses an infinite sum of only cosine waves to represent a target function whose left endpoint is $0$, by considering its even extension.  The even extension seems to amount to just adding a reflected version of the original function to the original function.
A Fourier Sine Series uses an infinite sum of only sine waves to represent a target function whose left endpoint is $0$, by considering its odd extension.  The odd extension seems to amount to just adding a rotated version of the original function to the original function.
On one hand, these cases do seem to have a certain special simplicity to them.  However, there are many other types of transformations, as well as many other sinusoid phases.  Is it possible, then, to create a different extension by adding a differently-transformed version of the original function to itself, with the end goal of using something other than $sin(x)$ or $cos(x)$ as the fundamental wave in its own Fourier ____ Series?
As a hypothesized example, would it be possible to add a version of a function to itself, which had undergone a transformation "half way between a reflection and a rotation," to create a Fourier Half-way-between-cosine-and-sine Series that uses $\cos(x - \frac{\pi}{4})$ as the fundamental wave?  If not, is there any other way to create such a series with $\cos(x - \frac{\pi}{4})$ (or an arbitrary-phase sinusoid) as the fundamental wave?
 A: You can represent a shifted square wave with a shifted Fourier series.

For example the shifted square wave with peak-to-peak amplitude $2$ and period $2 \pi$ defined as follows
$$f(t)=\left\{
\begin{array}{cc}
 -1 & -\frac{\pi }{4}\leq t<\frac{3 \pi }{4} \\
 1 & \frac{3 \pi }{4}\leq t<\frac{7 \pi }{4} \\
 f(t-2 \pi\ \text{sgn}(t)) & \text{True} \\
\end{array}
\right.\tag{1}$$
can be represented by the following shifted Fourier series:
$$f(t)=\underset{N\to\infty }{\text{lim}}\left(\sum_{n=1}^N a(n) \cos \left(n \left(t-\frac{\pi }{4}\right)\right)\right)\tag{2}$$
where
$$a(n)=\frac{2 \left(\sin \left(\frac{3 \pi  n}{2}\right)-\sin \left(\frac{\pi  n}{2}\right)\right)}{\pi  n}\tag{3}$$

The following plot illustrates formula (2) for $f(t)$ in orange overlaid on the reference function defined in formula (1) in blue where formula (2) is evaluated using an upper evaluation limit of $N=16$.


Figure 1: Illustration of Formula (2) for $f(t)$

As another example the shifted square wave with peak-to-peak amplitude $2$ and period $2 \pi$ defined as follows
$$g(t)= \left\{
\begin{array}{cc}
 -1 & -\frac{3 \pi }{4}\leq t<\frac{\pi }{4} \\
 1 & \frac{\pi }{4}\leq t<\frac{5 \pi }{4} \\
 g(t-2 \pi\ \text{sgn}(t)) & \text{True} \\
\end{array}
\right.\tag{4}$$
can be represented by the following shifted Fourier series:
$$g(t)=\underset{N\to\infty }{\text{lim}}\left(\sum_{n=1}^N b(n) \sin\left(n \left(t-\frac{\pi }{4}\right)\right)\right)\tag{5}$$
where
$$b(n)=-\frac{2 \left((-1)^n-1\right)}{\pi n}\tag{6}$$

The following plot illustrates formula (5) for $g(t)$ in orange overlaid on the reference function defined in formula (4) in blue where formula (5) is evaluated using an upper evaluation limit of $N=16$.


Figure 2: Illustration of Formula (5) for $g(t)$
