The standard way to calculate this function is by means of a loop structure.
However there is also a quicker way available if you consider f(c) as a combination of two functions:
........D....D' D
. . .
. . .
. . G
. . . .
. . . .
. G . C....C'
. . . . . .
. . . . . .
. . . . . .
. . . . . .
. . . . . .
H.......................C....C' H........................F
... . . .. . .
. . . . . . . . .
. . . . . . . . .
. . . . . . . . .
. . . . . . . . .
. . . F . . B....B'
. . . . . . . .
. . . . . . . .
. . . . . E .
. . . . . . .
. . . . . . .
A...........E...........B.....B' A........................A'
f1(c) f2(c)
We will start with the right drawing i.e. f2(c)
The right drawing consists of two triangles ABH and BCH. Triangle ABH consists of two equal legs AH and HB. The bottom leg is tilted over an angle w. The top angle is 2*w. Triangle BCH is of the same size. The first question is what is the angle B'BC
The left drawing is very much identical as the right drawing. The main difference is that the bottom leg AB is not tilted over an angle w. As a result the angle B'BC is not 3w but 2w.
Again also here you can repeat the same proces. The angle C'CD is not 5w but 4w. The next angle 6w.
The length of the projection of the line AC on the horizontal line AA'is equal to AB*cos(0) + BC*cos(2w) or x*cos(0)+ x*cos(2w). This is the "tot1" part of function f1(c).
Because the points A,B and C are on a circle we can also calculate the length of AC directly:
The total length (Sum of left and right part) of "tot1" part and with x = 1 is:
In order to calculate the FFT value the angle a0 has to be included. This is done by introducing the angle w0, which is equal to w0 = 2*pi*a0*c/q
The total length of "tot1" part including w0(i.e. a0) and with x = 1:
The total length of "tot2" part including w0(i.e. a0) and with x = 1:
This same strategy can be used to calculate the probablity p(c), but than w0 is not used i.e. w0=0.
Back to my home page Contents of This Document