Original file(SVG file, nominally 938 × 827 pixels, file size: 26 KB)

Summary

Description
English: This schematically represents how bind creates a new state processor (pAB) from a state processor (pA) and a processor-making function (f).

The equivalent verbose Haskell code follows. s1, s2 and s3 are actual states. v1 and v2 are values. pA, pB and pAB are state processors. Note that the wrapping and unwrapping by state/runState is implicit in the diagram.

-- pAB = s1 --> pA --> (v1,s2) --> pB --> (v2,s3)        
pAB = pA >>= f
    = state $ \ s1 -> (v2, s3)
        where
        (v1, s2) = runState pA s1
        pB = f v1
        (v2, s3) = runState pB s2
Date
Source Own work
Author Randall Britten

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

Captions

Add a one-line explanation of what this file represents

Items portrayed in this file

depicts

20 August 2013

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current00:05, 10 July 2015Thumbnail for version as of 00:05, 10 July 2015938 × 827 (26 KB)DuplodeUsing counter-tips in some arrows to work around a rendering bug in Chromium/Firefox.
23:06, 9 July 2015Thumbnail for version as of 23:06, 9 July 2015938 × 827 (25 KB)DuplodeRedrawn so that useful structure in the SVG is not lost.
17:41, 9 July 2015Thumbnail for version as of 17:41, 9 July 2015512 × 451 (161 KB)DuplodeSome adjustments for legibility and clarity.
05:49, 20 August 2013Thumbnail for version as of 05:49, 20 August 2013512 × 451 (82 KB)Randallbritten"Input" and "Output" of the final Lambda are now "protruding" from the boundary of the rectangle that represents the value of the bind. Also, slightly rearranged the arrows and layout, a bit tidier and more consistent.
22:45, 19 August 2013Thumbnail for version as of 22:45, 19 August 2013512 × 451 (81 KB)RandallbrittenUser created page with UploadWizard

The following 2 pages use this file:

Metadata