Abstract
More than being just a tool for expressing algorithms, a well-designed programming language allows the user to express her ideas efficiently. The design choices however effect the efficiency of the algorithms written in the languages. It is therefore important to understand how such choices effect the expressibility of programming languages.
The paper pursues the very low complexity programs by presenting a first-order function algebra BC\(^{\rm -}_{\epsilon}\) that captures exactly lf, the functions computable in logarithmic space. This gives insights into the expressiveness of recursion.
The important technical features of BC\(^{\rm -}_{\epsilon}\) are (1) a separation of variables into safe and normal variables where recursion can only be done over the latter; (2) linearity of the recursive call; and (3) recursion with a variable step length (course-of-value recursion). Unlike formulations of LF via Turing machines, BC\(^{\rm -}_{\epsilon}\) makes no references to outside resource measures, e.g., the size of the memory used. This appears to be the first such characterization of LF-computable functions (not just predicates).
The proof that all BC\(^{\rm -}_{\epsilon}\)-programs can be evaluated in lf is of separate interest to programmers: it trades space for time and evaluates recursion with at most one recursive call without a call stack.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
References
Barendregt, H.P.: The Lambda Calculus: Its Syntax and Semantics, revised edn. North-Holland, Amsterdam (1984)
Bellantoni, S., Cook, S.A.: A new recursion-theoretic characterization of the polytime functions. Computational Complexity 2, 97–110 (1992)
Bellantoni, S.J.: Predicative Recursion and Computational Complexity. Ph.D. thesis, University of Toronto, September 30 (1992)
Girard, J.-Y.: Light linear logic. Inform. & Comput. 143, 175–204 (1998)
Goerdt, A.: Characterizing complexity classes by higher type primitive recursive definitions. Theoret. Comput. Sci. 100(1), 45–66 (1992)
Hofmann, M.: Linear type and non-size-increasing polynomial time computation. In: Proc. 14th Ann. IEEE Symp. Logic in Comput. Sci. (July 1999)
Proc. Workshop on Implicit Computational Complexity (July 2002)
Immerman, N.: Languages that capture complexity classes. SIAM Journal of Computing 16(4), 760–778 (1987)
Jones, N.D.: The expressive power of higher-order types, or life without CONS. J. Funct. Programming 11(1), 55–94 (2001)
Kfoury, A.J., Mairson, H.G., Turbak, F.A., Wells, J.B.: Relating typability and expressibility in finite-rank intersection type systems. In: Proc. 1999 Int’l. Conf. Functional Programming, pp. 90–101. ACM Press, New York (1999)
Kristiansen, L.: New recursion-theoretic characterizations of well-knwon complexity classes. In: ICC 2002 [7]
Milner, R., Tofte, M., Harper, R., MacQueen, D.B.: The Definition of Standard ML (Revised). MIT Press, Cambridge (1997)
Møller Neergaard, P.: An example SML implemenation of a logspace linear bc evaluator (2003–2004)
Møller Neergaard, P.: Complexity Aspects of Programming Language Design—From Logspace to Elementary Time via Proofnets and Intersection Types. Ph.D. thesis, Brandeis University (October 2004)
Møller Neergaard, P., Mairson, H.G.: Types, potency, and impotency: Why nonlinearity and amnesia make a type system work. In: Proc. 9th Int’l. Conf. Functional Programming. ACM Press, New York (2004)
Murawski, A.S., Ong, C.-H.L.: Can safe recursion be interpreted in light logic? In: 2nd International Workshop on Implicit Computational Complexity (June 2000)
Papadimitriou, C.H.: Computatational Complexity. Addison-Wesley, Reading (1994)
Paulson, L.C.: ML for the Working Programmer, 2nd edn. Cambridge University Press, Cambridge (1996)
Pippenger, N.: Pure versus impure lisp. In: Conf. Rec. POPL 1996: 23rd ACM Symp. Princ. of Prog. Langs., pp. 104–109 (1996)
Voda, P.J.: Two simple intrinsic characterizations of main complexity classes. In: ICC 2002 [7]
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2004 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Neergaard, P.M. (2004). A Functional Language for Logarithmic Space. In: Chin, WN. (eds) Programming Languages and Systems. APLAS 2004. Lecture Notes in Computer Science, vol 3302. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-30477-7_21
Download citation
DOI: https://doi.org/10.1007/978-3-540-30477-7_21
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-23724-2
Online ISBN: 978-3-540-30477-7
eBook Packages: Springer Book Archive