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
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Jolly, R.: ScAS - Scala algebra system. Technical report (2010-2012), https://github.com/rjolly/scas
Kredel, H.: On a Java Computer Algebra System, its performance and applications. Science of Computer Programming 70(2-3), 185–207 (2008)
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
Davenport, J.: The axiom system. In: Proceedings of NAGUA 1991 (1992)
Gruntz, D., Monagan, M.: Introduction to GAUSS. SIGSAM Bulletin 28(2), 3–19 (1994)
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)
van der Hoeven, J., Lecerf, G., Mourrain, B.: Mathemagix. Technical report (2002-2012), http://www.mathemagix.org/
Niculescu, V.: A design proposal for an object oriented algebraic library. Technical report, Studia Universitatis “Babes-Bolyai” (2003)
Oliveira, B.C., Moors, A., Odersky, M.: Type classes as objects and implicits. SIGPLAN Not. 45(10), 341–360 (2010)
Watt, S.: Post facto type extensions for mathematical programming. In: Proc. Domain-Specific Aspect languages (SIGPLAN/SIGSOFT DSAL 2006), October 23. ACM (2006)
Weber, A., Klaeren, H.: Type systems for computer algebra. Relation 10(1.54), 2615 (1993)
Santas, P.S.: A type system for computer algebra. J. Symb. Comput. 19(1-3), 79–109 (1995)
Scala developpers: A tour of scala: Implicit parameters. Technical report (2008-2010), http://www.scala-lang.org/node/114
Osheim, E., Switzer, T.: Powerful new number types and numeric abstractions for scala. Technical report (2011-2012), https://github.com/non/spire
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights 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)