Skip to main content

Categories as Type Classes in the Scala Algebra System

  • Conference paper

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 8136))

Abstract

A characterization of the categorical view of computer algebra is proposed. Some requirements on the ability for abstraction that programming languages must have in order to allow a categorical approach is given. Object-oriented inheritance is presented as a suitable abstraction scheme and exemplified by the Java Algebra System. Type classes are then introduced as an alternate abstraction scheme and shown to be eventually better suited for modeling categories. Pro and cons of the two approaches are discussed and a hybrid solution is exhibited.

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

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Jolly, R.: ScAS - Scala algebra system. Technical report (2010-2012), https://github.com/rjolly/scas

  2. Kredel, H.: On a Java Computer Algebra System, its performance and applications. Science of Computer Programming 70(2-3), 185–207 (2008)

    Article  MathSciNet  MATH  Google Scholar 

  3. Odersky, M.: Poor man’s type classes. Technical report (Presentation at the meeting of IFIP WG) (2006), http://lampwww.epfl.ch/~odersky/talks/wg2.8-boston06.pdf

  4. Davenport, J.: The axiom system. In: Proceedings of NAGUA 1991 (1992)

    Google Scholar 

  5. Gruntz, D., Monagan, M.: Introduction to GAUSS. SIGSAM Bulletin 28(2), 3–19 (1994)

    Article  Google Scholar 

  6. Mechveliani, S.: Computer algebra with haskell: applying functional-categorial-“lazy” programming. In: Gerdt, V. (ed.) Proceedings of International Workshop CAAP, Joint Institute for Nuclear Research, pp. 203–211 (2001)

    Google Scholar 

  7. van der Hoeven, J., Lecerf, G., Mourrain, B.: Mathemagix. Technical report (2002-2012), http://www.mathemagix.org/

  8. Niculescu, V.: A design proposal for an object oriented algebraic library. Technical report, Studia Universitatis “Babes-Bolyai” (2003)

    Google Scholar 

  9. Oliveira, B.C., Moors, A., Odersky, M.: Type classes as objects and implicits. SIGPLAN Not. 45(10), 341–360 (2010)

    Article  Google Scholar 

  10. Watt, S.: Post facto type extensions for mathematical programming. In: Proc. Domain-Specific Aspect languages (SIGPLAN/SIGSOFT DSAL 2006), October 23. ACM (2006)

    Google Scholar 

  11. Weber, A., Klaeren, H.: Type systems for computer algebra. Relation 10(1.54), 2615 (1993)

    Google Scholar 

  12. Santas, P.S.: A type system for computer algebra. J. Symb. Comput. 19(1-3), 79–109 (1995)

    Article  MathSciNet  MATH  Google Scholar 

  13. Scala developpers: A tour of scala: Implicit parameters. Technical report (2008-2010), http://www.scala-lang.org/node/114

  14. Osheim, E., Switzer, T.: Powerful new number types and numeric abstractions for scala. Technical report (2011-2012), https://github.com/non/spire

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2013 Springer International Publishing Switzerland

About this paper

Cite this paper

Jolly, R. (2013). Categories as Type Classes in the Scala Algebra System. In: Gerdt, V.P., Koepf, W., Mayr, E.W., Vorozhtsov, E.V. (eds) Computer Algebra in Scientific Computing. CASC 2013. Lecture Notes in Computer Science, vol 8136. Springer, Cham. https://doi.org/10.1007/978-3-319-02297-0_18

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-02297-0_18

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-02296-3

  • Online ISBN: 978-3-319-02297-0

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics