Giter Site home page Giter Site logo

sharpmalib's Introduction

Project Description
Unified collection of Monads (M, unit, *) implemented in the Microsoft F# Language.

In functional programming, a monad is a kind of abstract data type used to represent computations (instead of data in the domain model). Monads allow the programmer to chain actions together to build a pipeline, in which each action is decorated with additional processing rules provided by the monad. Programs written in functional style can make use of monads to structure procedures that include sequenced operations, or to define arbitrary control flows (like handling concurrency, continuations, or exceptions).
Formally, a monad is constructed by defining two operations (bind and return) and a type constructor M that must fulfill several properties to allow the correct composition of monadic functions (i.e. functions that use values from the monad as their arguments). The return operation puts a value from a plain type into a monadic container of type M. The bind operation performs the reverse process, extracting the original value from the container and passing it to the associated next function in the pipeline.
(From Wikipedia. http://en.wikipedia.org/wiki/Monad_(functional_programming))

Monads Catalog:
Done:

  • Identity
  • Maybe
  • State
  • List
  • Error
  • Continuation


In Progress:

  • Parser


To do:

  • IO
  • ....


The monads are implemented in F#, but they can be used from both C# (LINQ) and F# (Computation expression)

References:
An Abstract View of Programming Languages by Eugenio Moggi

Monads for functional programming Philip Wadler
Merging Monads and Folds for Functional Programming by Erik Meijer , Johan Jeuring
The essence of functional programming
Monad Comprehensions: A Versatile Representation for Queries Torsten Grust
Real World Haskell: Code You Can Believe In (Paperback)

Monadic Parsing in Haskell by Graham Hutton and Erik Meijer
Monadic Parser Combinators by Graham Hutton and Erik Meijer

Any help on this project would be really appreciated since it is a potentially tricky one to get right.

sharpmalib's People

Contributors

holoed avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.