Try extending the range: for( doubled = -360 ; d < 361 ; d += 10 )
You've got something seriously wrong with those sine functions ("both" of them). The sine of an angle will be negative between 180 and 360 degrees (and also between -180 and 0 degrees).
(Clearly, sticking std:: there doesn't do what one might expect in terms of distinguishing functions, either!!!)
sin(35 degrees) is 0.573576
sin(35 radians) is -0.428182
So sin(35) is never 0.42.
Also, as lastchance points out, just using the result of the sqrt() always provides a zero/positive result which is only correct when 0 <= x <= PI Otherwise the result is negative.
But this is a strange way to obtain the value of sine() by using cosine() - and calling the function myPow().
To calculate sine from cosine is math. Simple exercise, isn't it?
Alas, the "formula" is correct for only half of the angles and then there are the rad/deg conversions.
Still, simple exercise that teaches something about <cmath>.
"myPow()" ... is clearly not an intuitive name for function that computes sine. Perhaps her_sin()?
you can do it less efficiently by chasing the unit circle. Use the equation of a circle, the known radius of 1, and distance formula or slope of the hypotenuse ... find points on the circle and you can get the angle and its trig values from sin = O/H tan = O/A etc. The points will have the +- signs for their quadrants and the signs will also work out. Not very efficient, but its a way to do it. The slope of the hypo is opposite over adjacent (aka rise over run) is the tangent which is sin(x)/cosin(x) blah blah..
you can of course use the taylor series as well. Its a very simple one.
I know the OP didn't want recursion, but I quite like this method. It's sweeter than the Taylor-series approach. For large angles it could be improved by reducing to the [0,2.pi] interval first, but that spoils the recursion a bit.