commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Li <rle...@gmail.com>
Subject Re: [math][all] Mentoring for Google's Summer of Code program
Date Sat, 04 Jun 2005 10:09:07 GMT
Following Al's suggestion (thanks Al!), I've made the following changes:

Core:
 
- polynomial & rational function interpolation

- univariate minimization

- univariate integration

- performance tuning for matrix computation and more decomposition
methods: mainly adapt code from other sources (Colt) assuming there is
no license issue


Additional (subject to discussion):

- generic (derivative-free) multidimensional optimization

- performance tuning for special functions

- FFT if it's not been worked on (I saw it on the wish list)

- initial value ODE package (RK & Multi-step)


Elsewhere (maybe merged back if there is enough interest):

- B-spline package (a generalisation of cubic spline which can handle
arbitrary order)

- optimization package

- PDE solver package


I'm going away for a few days due to exams but will be following the
discussion whenever possible.


Thanks,

Ryan


On 6/3/05, Al Chou <hotfusionman@yahoo.com> wrote:
> Ryan,
> 
> Your list below seems much more achievable.  I suggest cutting it even a bit
> further, say, dropping Gaussian quadrature as you already hint at (because
> implementing it would drag in some of the special functions that you note we
> don't have) and the ODE solver (unless all you mean is a simple initial value
> problem integrator, say 4th order Runge-Kutta).  I'm not familiar with B-spline
> or downhill simplex; univariate minimization is very close to root finding, as
> I'm sure you know, so I don't have a problem with including that.  And to
> actually expand the scope, maybe we could add rational function interpolation
> as well as polynomial.
> 
> To keep a flavor of typical software development in this project, I would also
> be interested to see the code be evolved from simple/naive implementations to
> the more sophisticated ones, at least for some parts of the project.
> Implementing a sophisticated algorithm from a reference work may feel good, but
> I argue you'll learn more about both the mathematics and about software
> development by taking baby steps and experiencing for yourself the reasons the
> more sophisticated algorithms became necessary or at least desirable.  In other
> words, it's OK to write a naive and slow but correct implementation and then
> modify it toward some more sophisticated version.
> 
> Finally, I wanted to clarify that I mistyped in my last post:  I meant to say
> that providing unit tests might be _less_ onerous if the code were done via
> TDD.  Testing an existing algorithm was always a pain to me early in my
> graduate career, and I learned through hard experience that it's necessary.
> Since then TDD has sprung up, and doing it actually makes writing tests (or
> executable examples, to be more accurate) feel good.
> 
> 
> Al
> 
> 
> --- Ryan Li <rleeuk@gmail.com> wrote:
> > Hi all,
> >
> > Many thanks for your comments so far (please keep them coming!). I do
> > realise that the proposal will probably take a number of specialised
> > numerical analysts a few months if not years to complete. I'm all for
> > cutting things down a bit (a lot rather), with an initial focus on the
> > more classical methods for which efficient algorithms are well
> > documented and can be implemented relatively easily. Seeing
> > commons-math as a generic and compact library based on which other
> > more sophisticated code can be written, I think the following could be
> > useful:
> >
> >       - performance tuning for matrix computation and add more decomposition
> > methods
> >       - univariate integration (Romberg is what I have in mind)
> >       - true polynomial interpolation, as opposed to spline, it will be
> > usually be used by other higher level numerical algorithms e.g.
> > Romberg integration or other Richardson extrapolation procedures
> >       - univariate minimization
> >       - robust derivative-free multidimensional optimization (downhill simplex)
> >       - B-spline
> >       - ODE solver
> >       - (maybe?) Gaussian quadratures
> >
> > and then possibly move to the more ambitious part. At some point I
> > would also like to add more special functions, and optimise the
> > performance of existing ones. Please let me know what you think about
> > this plan.
> >
> > I am actually a happy user of Colt myself, to me it seems that it
> > focuses on the data structure side of numerical computation (which it
> > does an excellent job), what I find it lacks specifically are the
> > algorithm side of things like root finding, interpolation,
> > integration, optimization (and possibly) ODE solver, the performance
> > of some of the special functions also left something to be desired
> > after they replaced the old IMSL code. There are scattered efforts on
> > all the things mentioned above, some seem to be quite mature but most
> > are experimental, I think it would be nice to have them all in one
> > library (maybe just adapt if license compatible and code reasonably
> > stable).
> >
> > As for code quality, I'll make sure I do extensive research into the
> > literatures and (probably more important) existing implementations in
> > whatever language before getting my hands on the keyboard, part of the
> > reason I wanted to start such a project is that when I was doing
> > coursework, I referenced many books and papers only to realise that
> > some of the ideas were clearly better than what I was suggested to do
> > in the project!
> >
> >
> > Best regards,
> >
> > Ryan
> >
> >
> > On 6/3/05, Rory Winston <rwinston@eircom.net> wrote:
> > > I agree, it is a hugely ambitious project. Which is not necessarily a bad
> > thing. I think a good start would be to qualify the scope of the project
> > sooner rather than later, and get a firm idea for exactly what will
> > (hopefully) be achieved.
> > >
> > > "Jakarta Commons Developers List" <commons-dev@jakarta.apache.org> wrote:
> > >
> > > >
> > > > Questions of scope of Commons-Math aside <gasp>, what is the scope
of the
> > > > summer project?  The scope of Ryan's proposal seems mighty ambitious,
> > even if
> > > > you remove the parts that aren't currently in scope for Commons-Math.
 If
> > you
> > > > intend to stay true to Apache's charter, the code will have to be
> > developed
> > > > firsthand, not copied from any other source, unless the license of the
> > source
> > > > is compatible or the author(s) are amenable to adding an
> > Apache-compatible
> > > > alternative license to their code or changing over to an
> > Apache-compatible
> > > > license.  Coding that much from scratch and providing JUnit tests will
be
> > a
> > > > heck of a lot of work (maybe a little onerous if you do TDD).  And
> > forgive my
> > > > skepticism, but code developed for coursework is unlikely to be as
> > bulletproof
> > > > as the proposal aims for.
> > > >
> > > > Also, specifically what parts of the proposal are not already addressed
> > by
> > > > existing libraries such as Colt?  I thought we were over the licensing
> > hurdle
> > > > for Colt, so anything it already does probably should not be duplicated
> > by code
> > > > newly written for the proposed project.
> > > >
> > > > All the above said, I'm not trying to be discouraging, and in fact I
> > would be
> > > > willing to participate in mentoring (I'll probably learn something new
> > > > myself!).  I just want reasonable expectations and goals to be set.  And
> > > > perhaps we can all ride the wave of youthful exuberance to grow a library
> > that
> > > > looks like the beginning of an "Apache-Math-Java".
> > > >
> > > >
> > > > Al
> > > >
> > > >
> > > > --- Phil Steitz <phil.steitz@gmail.com> wrote:
> > > > > I have volunteered to help Ryan with the proposal below and to serve
> > > > > as a mentor if it is accepted.  Pls see the links infra and the
> > > > > general Wiki page (http://code.google.com/summerofcode.html) for
more
> > > > > info on Google's  "Summer of Code".
> > > > >
> > > > > With Ryan's permission, I am forwarding the proposal.  The content
as
> > > > > stated clearly goes beyond the current scope of [math], but several
> > > > > items are in scope.
> > > > >
> > > > > Comments, please.  After a little discussion - including maybe the
> > > > > inevitable reopening of the "what do we want to be when we grow up"
-
> > > > > assuming others are favorable, I will work with Ryan to get something
> > > > > suitable onto the Wiki for consideration as one of the apache
> > > > > projects.  Comments from all commons community members are welcome.
> > > > >
> > > > > Thanks!
> > > > >
> > > > > Phil
> > > > >
> > > > > ---------- Forwarded message ----------
> > > > > From: Phil Steitz <phil@steitz.com>
> > > > > Date: Jun 2, 2005 4:50 AM
> > > > > Subject: [Fwd: Mentoring for Google's Summer of Code program]
> > > > > To: phil.steitz@gmail.com
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > -------- Original Message --------
> > > > > Subject: Mentoring for Google's Summer of Code program
> > > > > Date: Wed, 1 Jun 2005 07:23:25 -0700 (PDT)
> > > > > From: Ryan Li <rleeuk@yahoo.com>
> > > > > To: psteitz@apache.org
> > > > >
> > > > > Dear Phil,
> > > > >
> > > > > I'm just wondering if you or other developers of the The Jakarta
> > > > > Commons Math library would be interested in mentoring me for the
Google
> > > > > Summer of Code program (more details at
> > > > > http://code.google.com/mentfaq.html and
> > > > > http://code.google.com/summerofcode.html). Just so you know that
the
> > > > > Apache Software Foundation is already a mentoring organization
> > > > > (http://wiki.apache.org/general/SummerOfCode2005). Please see below
for
> > > > > my draft project proposal (as you can see I've already mentioned
the
> > > > > Jakarta Commons Math library in it and I've put down ASF as my mentor,
> > > > > so you or other team members will probably be contacted by Google
> > > > > soon).
> > > > >
> > > > > Thank you very much for your consideration!
> > > > >
> > > > > Ryan Du Li
> > > > > A college student specialising in optimization and numerical analysis
> > > > >
> > > > > ------------------------------
> > > > >
> > > > > Project description:
> > > > >
> > > > > Numerical Library for Financial Modelling / Scientific Computation
in
> > > > > Java (with a C# port)
> > > > >
> > > > > The goal of this project is to develop a reusable toolkit for
> > > > > developing mathematical models for valuing financial products and
risk
> > > > > management. Due to its numerical intensive nature, it can also be
used
> > > > > effectively in other applications that make uses of highly efficient
> > > > > numerical algorithms. Specific language features and design patterns
> > > > > will be used aggressively to allow for high performance and
> > > > > reusability. The C# port will be made in parallel as the Java version
> > > > > is developed, a number of features of C# (up to version 2.0) will
be
> > > > > used, in particular operator overloading will be used for all matrix
> > > > > operations.
> > > > >
> > > > > Highly efficient numerical algorithms will be implemented in the
> > > > > following areas:
> > > > >
> > > > > 1. a generic matrix and linear algebra package (including support
for
> > > > > dense and sparse matrices and commonly used decomposition methods),
an
> > > > > existing library might be used for this part of the toolkit.
> > > > >
> > > > > 2. an approximation package, with an emphasis on the support for
> > > > > B-splines, which is used to approximate curves in general, given
a set
> > > > > of points on the curve. Very useful for any sort of data fitting,
and
> > > > > heavily used in term structure modelling in finance
> > > > >
> > > > > 3. generic PDE/ODE solvers, with built-in support for Poisson/heat/wave
> > > > > equations. Useful in a large number of situations in modelling.
> > > > >
> > > > > 3. an optimization package, including linear programming (simplex
> > > > > method, later also interior point method), quadratic programming,
> > > > > nonlinear unconstraint/constraint minimization, later will also include
> > > > > search methods including genetic programming.
> > > > >
> > > > > 4. a simulation package, to provide a framework for running
> > > > > (Quasi)Monte-Carlo simulations
> > > > >
> > > > > 5. other essential tools, multi-dimensional numerical integration,
> > > > > Fourier transform, root-solver, interpolation/extrapolation, , special
> > > > > functions, statistical distributions.
> > > > >
> > > > >
> > > > > Current Java/C# open-source efforts in this area are limited (with
many
> > > > > projects abandoned or no longer actively maintained),  in particular
> > > > > useful things like B-Spline PDE-Solver, multi-dimensional numerical
> > > > > integration, Fourier transform are not addressed in any existing
> > > > > project I'm aware of (including most commercial ones). Also usually
not
> > > > > the most robust & efficient implementation is used whenever a
routine
> > > > > does exist, commercial projects have a significant advantage in this
> > > > > respect.
> > > > >
> > > > > Some of the code I've written for past school projects (I am a maths
> > > > > student specialising in optimization and numerical analysis) in the
> > > > > past will be adapted for various part of the toolkit. It is hoped
that
> > > > > by the end of summer the main components of the library will be ready
> > > > > for production use, and it will be actively developed and maintained
> > > > > afterwards.
> > > > >
> > > > > I've put down Apache Software Foundation as my sponsor as I noted
that
> > > > > they have a Commons-Math project
> > > > > (http://jakarta.apache.org/commons/math/) to which my project would
> > > > > complement very nicely.
> > > >
> > > > Albert Davidson Chou
> > > >
> > > >     Get answers to Mac questions at http://www.Mac-Mgrs.org/ .
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message