Page21
The
C++ opening and closing 'less than’, are substituted by # so as to avoid HTML
code confusion
The
'graphics' page has the proof included.
To
form the grid, g= the radius divided by four. To find the two sets of
coordinates on the hypotenuse, g= the radius divided by 512. The original
triangle used for the search had a base line of x+3000-r*cos(theta) and the
height, y-3000+r*sin(theta). Two 'for' loops were used, the first to reduce the
base by g while the second formed new triangles each with a reduced height,
returning to the first loop. The triangle that produced the needed co-ordinates
was x+14*g-r*cos (theta) and the height, y-8.25*g+r*sin (theta). The base line
was divided by g creating basecut, and then the hypotenuse was divided by
basecut, creating hypcut. A for i loop creates y, as in
sqrt(pow(hypcut*i,2)-pow(g*1,2)). x is declared an integer then x=y; if x==y
then y is an integer and can be found using the grid by dividing the result by
(r/4).
int x;
float r=200;circum=(2*M_PI)*r;area=(M_PI*pow(r,2);side=sqrt(area)/2;
theta=asin(side/r);base=(1400-(r*cos(theta)));g=r/512;
cut=(base/g);height=(825+(r*sin(theta)); hyp=sqrt(pow(base,2)+pow(height,2));hypcut=(hyp/cut);
for
(i=0;i#+hyp;i++)
{
y=
(sqrt (pow (i*hypcut,2)-pow (i*g,2)))/g;
x=y;
{
if(x==y)
cout##"-8.25*g+(y*g)/(r/4)
="## (-8.25*g+(y*g))/(r/4) ##"14*g-(i*g)/(r/4) ="##
(14*g-(i*g))/(r/4) ##;
endl;
}}
getch();
return
0; >