Skip to main content

Constructing medium sized efficient functional programs in Clean

  • Conference paper
  • First Online:
Advanced Functional Programming (AFP 1995)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 925))

Included in the following conference series:

  • 2192 Accesses

Abstract

As functional programming comes of age, writing medium sized functional programs (i.e. programs in the range of 10.000 to 100.000 lines of source code) becomes a realistic task. As a test case for development techniques for medium sized efficient functional program these notes describe the experience with writing in the functional language Clean a functional spreadsheet, i.e. a spreadsheet which has as its cell expression language a lazy functional programming language with the ability for the user to define lazy higher-order recursive functions.

An important aim of the design was to reuse existing functional software as much as possible. The resulting application uses about 25000 lines of Clean combining general components such as a window-based text editor, a symbolic evaluator and a high-level I/O library.

The design of the spreadsheet application (FunSheet) is shortly introduced, experience with development techniques for this application is discussed and some examples are given of general techniques for writing medium-sized functional programs that may be used in future experiments.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  • Achten, P.M., and Plasmeijer, M.J. 1994. A Framework for Deterministically Interleaved Interactive Programs in the Functional Programming Language Clean. In Bakker E. ed. Proc. Computing Science in the Netherlands, CSN'94. Jaarbeurs Utrecht. The Netherlands. Stichting Mathematisch Centrum, Amsterdam. pp. 30–41.

    Google Scholar 

  • Achten, P.M., and Plasmeijer, M.J. 1995. The Ins and Outs of Clean I/O, Journal of Functional Programming. 5 (1).

    Google Scholar 

  • Barendregt, H.P., Eekelen van, M.C.J.D., Glauert, J.R.W., Kennaway, J.R., Plasmeijer, M.J., and Sleep, M.R. 1987. Term Graph Rewriting. In Bakker, J.W. de, Nijman, A.J., and Treleaven, P.C. (editors), Proceedings of Parallel Architectures and Languages Europe, Eindhoven, The Netherlands, LNCS 259, Vol.II., pp. 141–158. Springer-Verlag.

    Google Scholar 

  • Barendsen, E., and Smetsers, J.E.W. 1993. Conventional and Uniqueness Typing in Graph Rewrite Systems (extended abstract). In Shyamasundar, R.K. (editor), Proceedings of the Thirteenth Conference on the Foundations of Software Technology and Theoretical Computer Science, Bombay, India, December 15–17, 1993. LNCS 761, pp. 41–51. Springer-Verlag.

    Google Scholar 

  • Brus, T., Eekelen, M.C.J.D. van, Leer, M.O. van, and Plasmeijer, M.J. 1987. Clean: A Language for Functional Graph Rewriting. In Kahn. G. (editor), Proceedings of the Third International Conference on Functional Programming Languages and Computer Architecture, Portland, Oregon, USA, LNCS 274, pp. 364–384. Springer-Verlag.

    Google Scholar 

  • Carlsson, M., and Hallgren, Th. 1993. Fudgets — A Graphical User Interface in a Lazy Functional Language. In Proceedings of the Conference on Functional Programming Languages and Computer Architecture. Copenhagen, Denmark, June 9–11, 1993, pp. 321–330. ACM Press.

    Google Scholar 

  • Cartwright, R., and Boehm, B. 1990. Exact Real Arithmetic, formulating real numbers as functions. In Turner, D.A. (editor), Research Topics in Functional Programming. University of Texas at Austin Year of Programming Series, pp. 43–64. Addison Wesley Publishing Company. ISBN 0-201-17236-4.

    Google Scholar 

  • Harper, R., D. MacQueen and R. Milner (1986). 'standard ML'. Edinburgh University, Internal report ECS-LFCS-86-2.

    Google Scholar 

  • Hoon, W.A.C.A.J. de 1993. Designing a spreadsheet in a pure functional graph rewriting language, Computer Science Master Thesis nr. 300, University of Nijmegen, The Netherlands.

    Google Scholar 

  • Hoon, W.A.C.A.J. de, Rutten, L.M.W.J., and Eekelen, M.C.J.D. van 1994. Fun-Sheet: A Functional Spreadsheet. Proceedings of the Sixth International Workshop on the Implementation of Functional Languages, Norwich, UK, September 1994, pp. 11.1–11.24.

    Google Scholar 

  • Hoon, W.A.C.A.J. de, Rutten, L.M.W.J., and Eekelen, M.C.J.D. van 1995. Implementing a Functional Spreadsheet in Clean. Journal of Functional Programming, Vol 3, 1995, to appear.

    Google Scholar 

  • Hudak, P., S. Peyton Jones, Ph. Wadler, B. Boutel, J. Fairbairn, J. Fasel, K. Hammond, J. Hughes, Th. Johnsson, D. Kieburtz, R. Nikhil, W. Partain and J. Peterson (1992). ‘Report on the programming language Haskell'. ACM SigPlan notices, 27, 5, pp. 1–164.

    Google Scholar 

  • Jones, M.P. (1993). Gofer — Gofer 2.21 release notes. Yale University.

    Google Scholar 

  • Nöcker, E.G.J.M.H., Smetsers, J.E.W., Eekelen, M.C.J.D. van, and Plasmeijer, M.J. 1991. Concurrent Clean. In Aarts, E.H.L., Leeuwen, J. van, Rem, M. (editors), Proceedings of Parallel Architectures and Languages Europe, June 1991, Eindhoven, The Netherlands. LNCS 506, pp. 202–219. Springer-Verlag.

    Google Scholar 

  • Peyton Jones, S.L., and Wadler, Ph. 1993. Imperative Functional Programming. In Proceedings of the Twentieth Annual ACM SIGACT-SIGPLAN Symposium on Principles of Programming Languages, Charleston, South Carolina, January 10–13, 1993, pp. 71–84.

    Google Scholar 

  • Plasmeijer, M.J., and Eekelen, M.C.J.D. van 1993. Functional Programming and Parallel Graph Rewriting. Addison Wesley Publishing Company. ISBN 0-201-41663-8.

    Google Scholar 

  • Plasmeijer, M.J., and Eekelen, M.C.J.D. van 1995. Clean 1.0 Reference Manual. Technical Report, in preparation. University of Nijmegen, The Netherlands.

    Google Scholar 

  • Pountain, D. 1994. Functional Programming Comes of Age. Byte Magazine, 19(8): pp. 183–184.

    Google Scholar 

  • Smetsers, J.E.W., Barendsen, E., Eekelen, M.C.J.D. van, and Plasmeijer, M. J. 1993. Guaranteeing Safe Destructive Updates through a Type System with Uniqueness Information for Graphs. In Schneider H.J., and Ehrig H. (editors), Proceedings Workshop Graph Transformations in Computer Science, Schloss Dagstuhl, January 4–8, 1993. LNCS 776, Springer-Verlag.

    Google Scholar 

  • Turner, D.A. 1990. An Approach to Functional Operating Systems. In Turner, D.A. (editor), Research topics in Functional Programming, pp. 199–217. Addison-Wesley Publishing Company, ISBN 0-201-17236-4.

    Google Scholar 

  • Turner, D.A. (1985). ‘Miranda: a non-strict functional language with polymorphic types'. In: Proc. of the Conference on Functional Programming Languages and Computer Architecture, ed. J.P. Jouannaud, Nancy, France. LNCS 201, Springer Verlag, 1–16.

    Google Scholar 

  • Vuillemin (1987). Arithmétic réelle exacte par les fractions continues. Technical Report 760. Institute National de Recherche en Informatique et en Automatique. Domaine de Voluceau, Roquencourt, BP105, 78153 Le Chesnay Cedex, France.

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Johan Jeuring Erik Meijer

Rights and permissions

Reprints and permissions

Copyright information

© 1995 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

van Eekelen, M.C.J.D., Plasmeijer, R.(.J. (1995). Constructing medium sized efficient functional programs in Clean. In: Jeuring, J., Meijer, E. (eds) Advanced Functional Programming. AFP 1995. Lecture Notes in Computer Science, vol 925. Springer, Berlin, Heidelberg. https://doi.org/10.1007/3-540-59451-5_6

Download citation

  • DOI: https://doi.org/10.1007/3-540-59451-5_6

  • Published:

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-59451-2

  • Online ISBN: 978-3-540-49270-2

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics