Saturday, June 9, 2012

The Fourier Transform

HOMEWORK
The Fourier Transform and its Applications, Brad Osgood
Free Online Course, Stanford University {course home}

The complete course materials, including all problem sets and answers can be found on the course home page.  I don't look at the answers.  Comprehension.  Comprehension.  Comprehension.  I'm also using the assignments to integrate SAGE into my math studies, to build worksheets and functioning code as I move forward.

QUESTION 1(a)
Find the sum of a geometric series for arbitrary start and end points:
          
where w ≠ 1 is real or complex, p and q integers.
Consider the cases p = −∞ or q = ∞.  What about (p = −∞ and q = +∞)?

A: Let S denote the sum.
       
  Then
       
  And hence
       
  for real or complex w.

Limits at infinity:
  i) w real
I have included unbounded limits.
  p → −∞
     • w > 1:   Then wp → 0.    S = wq+1/(w-1)
     • 0 < w < 1:  Then wp → +∞.  S = ∞  (S is unbounded.  The series does not converge)  
     • −1< w < 0: Then wp → ± ∞.  S =  ± ∞.
  (Consecutive terms have opposite signs. The alternating sequences w−2k,  w−(2k+1)  approach +∞ and −∞ respectively.)
      • w < −1 :  Then wp → 0.   S = wq+1/(w-1)
  (The alternating sequences of even and odd terms approach 0+ and 0, respectively.)

  q → +∞
     • > 1:   Then wq+1 → +∞.    S = +∞
     • 0 < < 1:  Then wq → 0+.  S = wp/(1−w)
     • −1< w < 0: Then wq → 0±.  S = wp/(1−w)
  (Alternating sequences of terms w2k,  w(2k+1)  approach 0+ and 0 respectively.)
      • < −1 :  Then wq → ± ∞.    S = ± ∞
  (The alternating sequences w2k,  w(2k+1)  approach +∞ and −∞, respectively)

  p → −∞    and   q → +∞
     • > 1:           Then     wp → 0,  wq+1 → +∞.      S = +∞
     • 0 < < 1:  Then   wp → +∞,    wq → 0+.       S = +
     • −1< w < 0: Then  wp → ± ∞,    wq → 0±.      S = ± ∞
     • < −1 :        Then    wp → 0,     wq → ± ∞.     S = ± ∞

 ii) w complex:  w = a + bi,   b ≠ 0
Now that is a good question.
What are the conditions of convergence?
 Magnitude: 
   • Case 1:  |w| = √(a2 + b2) > 1.   Then  wq → 0 as  q → ∞,
   • Case 2:  |w| < 1.                        Then     wp → 0  as  p → −∞
In both cases, whenever wn does not go to zero, (I believe)  both a and b → ± ∞.  This is easy to see if we begin with w purely imaginary.  For any four consecutive integral powers, the resulting single term will cycle through the four states of in:  {+,  +i,  −,  −i}.  Both the sequence and series approach the limits ∞ −∞, ∞i, −∞i   in four alternating sequences.  I believe the series approaches the same four limits simultaneously for all |w| > 1, a≠0, ≠0, by interleaved combinations of ±a and ±b.  It should be possible to determine, for any particular w, the arrangement of those terms for sequential powers by examining the argument of w:
       Arg(w) = θ,
      where   a = cos θ,     b = sin θ
It seems obvious that the series cannot converge to a particular angle measure, as even division of the circle length cannot be given by a rational expression.  However, I have left off there; my impression is that this work is beyond the scope of the question.
For complex w there is also a
      Case 3:  |w| = 1.   Then there is no limit for a or b.  Arg(w) should likewise have no limit, as successive powers are polynomial expressions.  However, |wp|, and |wq+1| = 1 for all values of p and q.  The resultant vectors are rotations around the unit circle; each successive power should produce an angle different from all preceding angles.
I have not verified this, except for double-checking that it is impossible for any angle but zero to be preserved under squaring.  Hard to know how much detail other people think is normal.

QUESTION 1(b)
Find the sum
          
and explain your answer geometrically.
A: Let S denote the sum.
     
  The ratio of consecutive terms is
     
  Then
     
  And hence
     
Geometrically, the situation is straightforward.  By construction, the N terms are evenly spaced points along the arc [0, 2π) of the imaginary unit circle.  The angle measure at each point is is the same as the arc length from zero; i.e.
  • the cosine of each angle = the real component of each term = the projection of the point on the real axis
   •the sine of each angle = the imaginary component = the projection onto the imaginary axis
Each of these sums (real and imaginary) is zero for all whole numbers N > 1.

QUESTION 1(c)
   (c) Derive the formula
         

A: Let S denote the sum
     
  The ratio of consecutive terms is
     
  Following the same procedure,
     
 This could get ugly.  Preliminaries:
  
  Basic formulas:
     cos(−θ) =  cos(θ),       sin(−θ)  =  −sin(θ)
     sin(2θ)  =   2sinθ cosθ,
     cos(2θ) =  2cos2θ −1  =  1− 2sin2θ
     the addition and subtraction formulas for sine and cosine
  Collecting some terms,

     
  Applying the double-angle formulas, and cleaning up a bit:
     
  Go away, Red guys. Move the leading −i into the square brackets:
     
  Which has the conspicuous form of an angle sum:
     
Tits.  Maybe I missed an easier way.  I'll look at the answers after I have posted mine.

QUESTION 2
Represent each of the figures (a) - (d) as the sum of two isosceles triangles,  in the form,
     
  where

When the midpoints of the triangles do not coincide, call the leftmost triangle Λa1, and the rightmost, Λa2.

I have also written each figure as an adjacency list (a vector). Reading left-to-right, connecting adjacent points with straight lines gives the figure.

(a)   [(-2, 0), (0, 1), (2, 1), (4, 0)]   = Λ2(t) + Λ2(t −2)

(b) [(-2, 0), (0, 2), (1, 1), (2, 1), (3, 2), (5, 0)]   = 2Λ2(t) + 2Λ2(t −3)

For both (c) and (d), let's invent a petit theorem:
Theorem: The apex of one (or both) of the triangles occurs at the maximum value of the envelope.
{Note that the maximum value is not restricted to occur only at the apex positions}.

PROOF: The maximum value of each triangle is the apex, at ci.  Consider their sum.
Case 1: Let the peaks of the two triangles coincide.  The highest point of the sum is of course at this common point.  In math,
     Let c1 = c2
     Then max(Λa1) + max(Λa2) = max(Λa1 + Λa2),   at    t = c1c2.
Case 2: Separate the peaks by a small amount, δ, so that cc2. For all t < c1, and t > c2, the direction of increasing Λa1 and Λa2 is into the interval c1 ≥ t ≥ c2.  The maximum value must then lie in c1 ≥ t ≥ c2.
Let the slopes of the two triangles be m1 = (ΔΛa1 / Δt), and  m2 = (ΔΛa2 / Δt).
Now consider m+ m2, only over the interval  c1 ≥ t ≥ c2.   The slopes have opposite sign: there is some α > 0 such that m1 = −α m2.
(I consider only the case where the triangles are sufficiently close that neither m1 nor m2 falls to zero in the interval.  If the triangles are moved farther apart... oh, hell... the proof is even easier that way, but I will finish it this way, and it should be clear the proof always holds as the triangles are moved farther apart.)
Suppose α=1, then the maximum value of  m1m= 0.  The sum is a horizontal line, with breakpoints at c1 and c2.  Then max(Λa1 + Λa2) occurs at both c1 and c2 (and everywhere in between).
Suppose α ≠ 1.  Then one of the two, |m1| or |m2| is greater.  Suppose |m1| > |m2|.  Now, the minimum value of Λa1 on the interval is at the rightmost point, c2.  Moving to the left, m1 is positive, m2 is negative, and |m1| > |m2| and therefore the sum m1+m2 is positive over the entire interval, to the maximum value of Λa1, at c1.  
If |m2| > |m1|, the procedure is the same, but moving from right to left.
Hence, the maximum value of  Λa1Λa2  invariably coincides with the apex of one (or both) of the triangles.

(c)  [(1, 0), (3, 6), (7, 0)] =   6Λ2(t−3) + 3Λ2(t −5)
(d) The question appears to be, "under what conditions is the sum a triangle with unequal sides?"

Working this out in Sage, I have a couple of clunky cases, with proofs.  The answer is simple, and but piecewise functions make the algebraic arguments a bit messy.  The main point is this: Each triangle has 3 corners where the slope changes:  The function is zero; it goes up; it goes down. No mystery here: it's a triangle.  The sum then has at most six corners.  What are the conditions for a sum with only three?  First, there are three corners if the x-coordinates of the three corners are identical for both triangles.  That is,
Case 0: The sum is a triangle with equal sides.  The two triangles have the same base, and the same center.  a1=a2, c1=c2.  That is, the peaks and base coincide.  But we're really interested in the next two cases where,

The sum is a triangle with unequal sides.
Suppose only two of the three x-coordinates are shared between the triangles.  
Consider the following diagram/solution:
Case 1:
The apex of each triangle coincides with an endpoint of the other:  a1=a2.
Then c2 divides the longer side into two equal segments.  For the two sections to form an unbroken line, over the same change in t we must have:

rise(Λ1) − rise(Λ2) = rise(Λ2)
rise(Λ1)  =   2 rise(Λ2)
Hence b1 = 2b2.  Equivalently, the slope of Λ1 is twice that of Λ2.
In terms of Lambda,  the sum is
          
where the first is a left-shouldered triangle, the second is right-shouldered.
case 2:
Here, the triangles share a common endpoint

Again, in terms of Lambda, we have
          
What is common to both cases? The conditions are:
1) One of the triangles must have a slope twice that of the other.
2) the ci satisfy c2 = c1 + a, independently of how we choose to construct the 2:1 slope ratio.
Synthetically, in the expression
          
we can place the numeral 2 in one of four possible positions: before a or b in either of the bΛa.
{remaining to do: double check that it is not possible have a triangle sum with only one shared corner.}

There are a number of ways to assemble the same conclusion.  Note, for example, that, by the little Theorem one of the triangles must have a peak at x2.  Its base can extend no further than x1, and therefore the second triangle must have a base which extends to x3.  This insures that the peak of the second triangle must occur to the right of x2.  The furthest to the left c2 may be is the midpoint of the base.  There are two cases.  Suppose c2 lies on the midpoint.  Then for the left endpoint we have c1a1 = c2a2.
Suppose c2 lies to the right of the midpoint... etc.
{Document getting long.  To be continued}

Tuesday, June 5, 2012

Blizzard, June

To Our Brown-eyed Cousin,

Selky daughter, split-tongued; who wears the river, skirt-and-trouser;

I have always preferred to mock the donning of garlands, and laugh at each pronouncement of the phases of the moon.  Today the stories are no longer a game.  Your friends have been murdered and a white sill advances into the chest of the living.  None of this is alright, and I was foolish to say otherwise.

We know the Queen abducts the body.  She took us as presents; bound in furs and sleep.  This is why we practiced.   The chill curtain is our common enemy, and we are not without recourse: we are at ease with winter; the ice moon is ours.

There are three months between us and the boyish Harvest-moon, and then the Blood.  You intend to our shore by September. Then, come.  The vote has been called, and counted.  We request your presence among us, by the Harvest moon.

This date passing without sign of your arrival, I am prepared to hunt you, bring you across the river. You never have to go back.

The objections have been heard, and dismissed.  We summarize:

That we are allied with the Snow Queen.
We stole the bodies of boys and unknotted her violet dresses.  It is true.  I wear the bolt through the chest, still.  The allegiance is renounced.

On the division Seele - Unseele
We declare it null.  Let them say fortune, misfortune.  Favor and disfavor.  Nonsense.  We have not found our hearts so divined, nor the navigable world so divided.  The storm is everywhere.  Dreams come, regardless.  Terror creeps under the windowsill; I shake in the arms of lovers.  Neither pole withholds itself.
The borderlands are undivided and we believe this fact is plain to you.

That our mouths are dangerous
Well.  We are toothed.  So are you.

We love our neighbor, crooked, and hope that she is crooked in turn.
Let me walk alongside you in the dark.

It is therefore decided to send for you , to live the winter among us.  All hands assent.
Promulgated this second rose day of June.


     We remain your most humble & c.

     The wolves.