Ticket #1600 (new proposed-project)

Opened 2 years ago

Last modified 14 months ago

Mathematical environment in Haskell

Reported by: serras Owned by:
Priority: OK Keywords:
Cc: Topic: misc
Difficulty: unknown Mentor: not-accepted

Description (last modified by carette) (diff)

Haskell is usually described as a language appropiate for people with a mathematically-oriented mind. However, I've found that there is no comprehensive library (or set of libraries) for doing maths in Haskell.

My idea would be to follow the path of the Sage project  http://www.sagemath.org/. That projects took a lots of libraries and programs already available and added a layer for communication with them in Python. The result is that now you can have a full-fledged mathematical environment while using your normal Python knowledge for GUI, I/O and so on...

The project can have several parts:

  • Try to come with a hierarchy of classes like the ones in Sage for the basic building blocks (this may start with the Numeric Prelude)
  • Try to create bridges in Haskell as done in Sage
  • Find a way to "import" code in Sage (some algorithms are written just in them) to the Haskell counterpart

For free, GHCi could be used as the next Matlab :D

Interested students

  • Alejandro Serrano (serras)

Interested mentors

  • Jacques Carette <carette@…>

Change History

Changed 2 years ago by serras

  • description modified (diff)

Changed 2 years ago by gbaz

This sounds to vague to be a good soc project. It needs to be done by a single student in a single summer and to not involve a great deal of API design.

A good proposal should have some more concrete goals -- is there a "core" subset of SAGE functionality that Haskell lacks, but which makes it a good tool? Better yet, are there good math/science libs that sage binds to but which we don't have Haskell bindings for? What are they? Could we produce robust, maintainable bindings over a summer? Would those be worthwhile in themselves?

Changed 2 years ago by gbaz

Ok here's one idea -- one killer feature of sage is the notebook. Can we generalize this a bit? In particular, coudl we make some sort of online code executor/notebook that provides the nifty sage features for formatting and producing graphs that are math specific as well as more general utility as a haskell codepad? There are pieces out there to pull together -- from some of the components of gitit and pandoc to execution either dynamically as with barley[1] or using mueval [2] or even just driving ghc directly with runProcess. The notion is a web-hosted graphical notepad like tool for calculating (and collaborating) with Haskell.

[1]  http://mtnviewmark.wordpress.com/2010/10/21/haskell-rapid-transit/ [2]  http://hackage.haskell.org/package/mueval

Changed 2 years ago by serras

That would be a great idea :D

Maybe the idea would be the following: create a Sage-like notebook for running Haskell code in a GHCi-like way. It can have syntax coloring, some help from Hoogle... Indeed, it can be a great tool for learning and teaching Haskell.

At the same time other tools may be provided: - If the returned value implementes some class, say SageViewable?, we can show it to the user. That may be interesting for showing from pictures, to graphs, to matrices. - The code could be backed up in some sort of Darcs repository.

Of course, this should be done in some Haskell web frameworks, so may be a good test-suite for any of them.

Should I create a new ticket for this idea or change this ticket to reflect it?

Changed 2 years ago by tibbe

  • priority changed from not yet rated to OK

Changed 14 months ago by carette

  • description modified (diff)

This is really hard... But I would be willing to supervise.

Changed 14 months ago by mcandre

Correct, there are scattered libraries for mathematics but no collective framework.

For example, the transition between an hmatrix and a vector should be more seamless.

Note: See TracTickets for help on using tickets.