The Band Played Waltzing Matilda – June Tabor

Folk singer June Tabor is as far as I’m aware the first artist to record Eric Bogle’s The Band Played Waltzing Matilda. This is in my opinion the definitive version.
We are supposed to learn from our mistakes but never seem to and year after year the cannon fodder gets sent to some front line somewhere

 
One of the Youtube comments linked to an excellent article on the song, the writer (Eric Bogle), and the part played by June Tabor’s version:

Secret Life of Matilda

Has the software and information on this blog saved you time and money?  If so, please contribute to my daughter’s short film project:

Long Lost, a WW1 short film – crowd funding site

 

Posted in Bach, Films | Tagged , , , , | Leave a comment

Using the VBA ParamArray keyword

The recently posted SolvePoly function makes use of the VBA ParamArray keyword, which allows an arbitrarily long list of arguments to be passed to another function.  I have not made great use of this in the past, but since the structure is similar to a Python list of lists it forms a convenient way of transferring data to and from Python routines, as well as being useful in a pure VBA context.

The full code of the PolySolve function is shown below:

Function SolvePoly(ParamArray CoeffA() As Variant)
Dim i As Long, PArray As Variant, Num_Coeff As Long

    Num_Coeff = UBound(CoeffA) + 1
    ReDim PArray(1 To Num_Coeff, 1 To 1)
    For i = 0 To Num_Coeff - 1
        PArray(i + 1, 1) = CoeffA(i).Value2
    Next i

    Select Case Num_Coeff
    Case Is < 3:
        SolvePoly = "Num_Coeff must be >= 3"
    Case Is < 4:
        SolvePoly = Quadratic(PArray)
    Case 4:
        SolvePoly = CubicC(PArray)
    Case 5:
        SolvePoly = Quartic(PArray)
    Case Else:
        SolvePoly = RPolyJT(PArray)
    End Select
    SolvePoly = WorksheetFunction.Transpose(SolvePoly)
End Function

The rules for using ParamArray are:

  • Any non-optional arguments must be declared first.
  • The argument passed by ParamArray must be declared as a variant array, including the “()”.
  • ParamArray cannot be used in conjunction with ByVal, ByRef or Optional.
  • Each argument in the ParamArray array may be any data type, including variant arrays, ranges or objects.
  • The argument passed by ParamArray is a 1D base 0 array
  • Each argument is optional, but if optional arguments are expected they must be checked using the IsMissing function.  In the case of the SolvePoly function an empty argument in the list (e.g. =solvepoly($B$12,$B$13,,C12)) will cause an error at the line:  PArray(i + 1, 1) = CoeffA(i).Value2
  • When calling the function, either from the worksheet or from another VBA function, each argument is listed separately.  They are combined into a variant array automatically.

In the case of the SolvePoly function the CoeffA argument was required to pass an arbitrary number of double values, which were then converted into a 2D array, as expected by the subsequently called functions.  A Select Case statement was then used to call one of 4 functions, depending on the length of the PArray array.  Note that the final RPolyJT function will accept an array of any length, so PolySolve will handle any number of input arguments greater than 2.

Posted in Excel, Maths, Newton, UDFs, VBA | Leave a comment

Is Hinchliffe’s Rule True? …

… is the title of a paper by Boris Peon. Here is the abstract:

Hinchliffe has asserted that whenever the title of a paper is a question with a yes/no answer, the answer is always no. This paper demonstrates that Hinchliffe’s assertion is false, but only if it is true.

From New Scientist, 16 August 2014

Download the full paper

 

Posted in Newton | Tagged | 2 Comments

Long Lost, a WW1 short film …

… and crowd-funded production, directed by my daughter:

The story of the project

At the start of 2014, sparked by the funding opportunity Raw Nerve (A Metroscreen and Screen Australia initiative) Kerinne Jenkins (director), Harry Windsor (writer) and Nic Douglas (producer) conceived of the short film “ Long Lost”.

After applying with a video pitch, our project was chosen as one of three successful candidates. We were then invited to participate in a three-month development process with the other Breaks filmmakers and mentors Lachlan Philpott, Karel Segers and Jonathan Wald.

Now that the script has been developed, we’ve been given a start in realizing this project, with an initial amount of funding and it’s up to us to raise the rest to bring this story to life.

Visit the link below, have a look at the video with more on the background to the project, and contribute to allow it to proceed:

Long Lost – crowd funding site

Posted in Bach, Films | Tagged , , | Leave a comment

Numerical Integration; Tanh-Sinh Quadrature v. 4.2

The latest version (4.2) of the numerical integration spreadsheet by Graeme Dennes is now available for download from Tanh_Sinh Quadrature.

For more details of the background see: Faster Integration with the Tanh-Sinh Method and subsequent posts on this subject.

In addition to the code and examples on the use of Tanh-Sinh quadrature and a number of other techniques, the download file contains examples and thoroughly documented code for a range of other spreadsheet and VBA functions, including:

  • Dynamic linking of graphs to function results, without writing the results to the spreadsheet
  • Evaluating functions entered as text on the spreadsheet
  • Timing of function execution time with a high precision timer
  • Accurate determination of processor constants, such as maximum an minimum floating point values.
  • VBA code for the complete range of standard trigonometry functions
  • Examples of incorporating the quadrature functions in other routines.

The revisions included in Ver. 4.2 are listed below.  In the next post in this series I will look in more detail at how these functions can be incorporated in other spreadsheets.

Version 4.2 Release Notes

  1. Following a private suggestion, all quadrature programs now provide the number of function evaluations as a more useful performance metric.
  2. The Romberg program runs in 30 percent of the time taken by the previous (V4.1) release, and accuracy averages only one digit less than Tanh-Sinh. The Romberg algorithm implemented herein by the author may be the fastest and most accurate to date.
  3. The function plotter is located on a separate worksheet for convenience.
  4. Finite interval test functions total 400, which may be the largest set of diverse test integrals available (with answers) at no cost.

Graeme Dennes

 

Posted in Excel, Maths, Newton, Numerical integration, UDFs, VBA | Tagged , , , , , , , , | 2 Comments