 ## Self ex-spline-atory

Visible to anyone in the world
Edited by Valentin Fadeev, Thursday, 27 Mar 2014, 10:06

M832 did not really fit in the "big picture" of my study plan this year, not only because I am notoriously bad at numerical calculations. Having invested a lot of effort and sleepless nights in developing intuition for the behaviour of analytic functions I was suddenly confronted by the cubic splines which seemed to have all those properties, that well-mannered functions would be never allowed to possess.

Nicely, but artificially glued together of several pieces of cubics, smooth only up to the second derivative, vanishing on the entire intervals, now this is what seems really counter-intuitive. Be that as it may, the TMA deadlines had to be met.

The following is the kind of problem I got stuck with for a while. Obviously I am not replicating a TMA question here, giving an extended solution to one of the problems from the Course Notes. So the task is to express a function, say in terms of cubic B-splines on the entire real axis. I am omitting a lot of background material focusing on one particular idea that arises in the solution.

Since has a supporting interval of length 4 outside which it vanishes, we can start by expressing the function in terms of on and then try to extend the result. Calculating the expressions for the splines on :

multiplying by the respective coefficients, summing and equating powers of on each side we arrive at the following system of equations:

Having the solution (guaranteed by the Schoenberg-Whitney theorem):

Now we want to find all coefficients on each of the intervals for the points . From the general expression for the B-spline it can be deduced that

which for leads to the following recurrence relation:

or, after changing the index

Now here is the trick that I came up with and that was not (at least not explicitly) described in the Course Notes or the set book. The last expression can be thought of as a "second-order linear inhomogeneous recurrence relation". The advantage of this approach is that the structure of the solution instantly becomes clear.

The general solution of the corresponding homogeneous relation

is derived in the course notes, using the standard method of solving this type of recurrencies and is given by the following expression:

It can also be found using generating functions. Not surprisingly it depends on 2 arbitary constants, as it takes 2 initial terms, and to reconstruct the whole sequence from the three-term recurrency. Applying the general ideas from the linear systems we deduce that in order to obtain the general solution of the inhomogeneous recurrency we have to add a particular solution to the expression above.

Since the RHS is the quadratic polynomial it makes sence to look for the particular solution in the form:

Substituting this into the original recurrency and gatherig together the powers of we obtain:

which after equating powers gives the solution

Thus the general solution of the inhomogeneous equation is given by the following formula:

Now we can use the values of and to determine the constants (bearing in mind that ):

which gives . Thus finally:

which is the solution of the original problem.

Share post

## Around the infinity

Visible to anyone in the world
Edited by Valentin Fadeev, Sunday, 18 Sep 2011, 23:23

Now I got really fascinated with this topic. The most exciting part of evaluating integrals using residues is constructing the right contour. There are general guidelines for certain types of integrals, but in most cases the contour has to be tailored for a particular problem. Here is another example. Evaluate the following integral:

Where are real,
are roots of the integrand.

The approach used in the previous example does not work as the integral along a large circle centered at the origin does not tend to 0. This, in fact, is a clue to the solution, as it prompts to have a look what indeed is happening to the function for large . But first consider the integrand in the neighborhood of the origin (simple pole):

Now the integrand is regular for large hence it can be expanded in the Laurent series convergent for where is large:

The residue at infinity is defined to be the coefficient at with the opposite sign:

Now we construct contour C by cutting the real axis along the segment and integrating along the upper edge of the cut in the negative direction, then along a small circle and along the lower edge of the cut. As the result of that one of the factors of the integrand increases its argument by
. Finally integrate along a small circle

Integrating along this contour amounts to integrating in the positive direction along a very large circle centered at infinity. Hence the outside of C is the inside of this large circle which therefore includes both the residue at the origin and at infinity. Therefore, by the residue theorem:

Share post

## How comple^x can you get? Continued

Visible to anyone in the world
Edited by Valentin Fadeev, Thursday, 27 Mar 2014, 10:11

As a follow up thought I realized just how much easier it would have been to calculate the residue by definition, i.e. expanding the integrand in the Laurent series to get the coefficient . Let where is small:

Of course, care is needed when choosing the value of the root. It depends on the value of the argument set on the upper bound of the cut. Since I chose it to be 0, the correct value of the root is .

Now

Therefore, near the integrand has the following expansion:

where is the regular part of the expansion which is of no interest in this problem.

Hence by definition:

Share post

## How comple^x can you get?

Visible to anyone in the world
Edited by Valentin Fadeev, Thursday, 21 Apr 2011, 23:58

I found this example in a textbook dated 1937 which I use as supplementary material for M828. It gave me some hard time but finally sorted out many fine tricks of contour integration. Some inspiration was provided by the discussion of the Pochhammer's extension of the Eulerian integral of the first kind by Whittaker and Watson.

Evaluate the following integral:

Consider the integral in the complex plane:

where contour C is constructed as follows. Make a cut along the segment of the real axis. Let on the upper edge of the cut. Integrate along the upper edge of the cut in the positive direction. Follow around the point along a small semi-circle in the clockwise direction. The argument of the second factor in the numerator will decrease by . Then proceed along the real axis till and further round the circle in the counter-clockwise direction.

This circle will enclose both branch point of the integrand and , however since the exponents add up to unity the function will return to its initial value:

This is the reason why we only need to make the cut along the segment and not along the entire real positive semi-axis. Then integrate from in the negative direction, then along the second small semi-circle around the point where the argument of the second factor will again decrease by . Finally integrate along the lower edge of the cut and along a small circle around the origin where the argument of the first factor will decrease by . As the result of this construction the integral is split into the following parts:

Two integrals around the small circles add up to an integral over a circle:

Similarly, the integral around a small circle around the origin vanishes:

Integrals along the segment cancel out:

The integral over the large circle also tends to 0 as R increases. This can be shown using the Jordan's lemma, or by direct calculation:

Finally the only two terms that survive allow us to express the contour integral in terms of the integral along the segment of the real axis:

The contour encloses the only singularity of the integrand which is the pole of the third order at . Hence, by the residue theorem:

The residue can be calculated using the standard formula:

Calculation of the derivative can be facilitated by taking logarithm first:

Share post

## Going beyond dx

Visible to anyone in the world
Edited by Valentin Fadeev, Sunday, 18 Sep 2011, 23:23

This is quite a minor trick and like many things listed here may seem quite trivial. However, this is one of those few occasions when I had the tool in mind, before I actually got the example touse it on. Consider:

which does not really require a great effort to solve. But forget all the standard ways for a moment and add to both parts:

Hope this can be stretched to use in more complicated cases

Share post

## Vector horror

Visible to anyone in the world
Edited by Valentin Fadeev, Sunday, 23 Jan 2011, 21:49

Had to do some revision of vector calculus/analysis before embarking on M828.

One point which I was not really missing, but did not quite get to grips with was the double vector product. I remembered the formula:

,

but nevertheless had difficulties applying it in excercises.

The reason whas that that the proof I saw used the expression of vector product in coordinates and comparison of both sides of the equation. However, I was aware of another, purely "vector" argument with no reference to any coordinate system.

Eventually I was able to reproduce only part of it, consulting one old textbook for some special trick. So here's how it goes.

For is perpendicular to the plane of and , must lie in this plane, therefore:

Dot-multiply both parts by :

Since , left-hand side is 0, so:

Now define vector lying in the plane of and , perpendicular to and directed so that , and form the left-hand oriented system. This guarantees that the angle between and , .

Dot-multiply both parts by :