User:LucasVB/Square sine and cosine functions

The square sine and square cosine functions are akin to their trigonometric counterparts, but instead of defining an unit circle, they define a square of "radius" 1 (that is, side 2). I'm not sure if such functions are already properly defined in the mathematical community, but I never heard of them. I doubt I'm the first to toy with this concept, though.
The square sine ("sinsk") can be written as:
Where sgn is the very useful sign function. The signal function works here as a very useful inline hack for a piecewise function construction. There's probably a better way to do all this, but hey, it works so far!
The square cosine ("cosk") is defined as:
Approximations
An interesting approximation can be done by using iterated trigonometric functions:
Define a function ts such as:
The square sine can then be approximated by:
Which gives a smooth curve that differs no more than 0.1082300356377... from the square sine. I wonder if there's a better approximation...