Ramesh Subrahmanyam - Academia.edu (original) (raw)

Papers by Ramesh Subrahmanyam

Research paper thumbnail of Data Abstra>ct ion a,nd General Recursion

Existing approaches to semantics of algebraically specified data types such as Initial Algebra Se... more Existing approaches to semantics of algebraically specified data types such as Initial Algebra Semantics and Final Algebra Semantics do not take into account the possibility of general recursion and hence non-termination in the ambient programming language. Any technical development of this problem needs to be in the setting of domain theory. In this paper we present extensions of initial and final algebra semantics to algebras with an underlying domain structure. Four possibilities for specification methodologies arise: two each in the Initial and Final algebra paradigms. We demonstrate that the initial/final objects (as appropriate) exist in all four situations. The final part of the paper attempts to explicate the notion of abstractness of ADT's by defining a notion of operational semantics for ADT's, and then studying the relationship between the

Research paper thumbnail of Data Abstraction and General Recursion

Existing approaches to semantics of algebraically specified data types such as Initial Algebra Se... more Existing approaches to semantics of algebraically specified data types such as Initial Algebra Semantics and Final Algebra Semantics do not take into account the possibility of general recursion and hence nontermination in the ambient programming language. Any technical development of this problem needs to be in the setting of domain theory. In this paper we present extensions of initial and final algebra semantics to algebras with an underlying domain structure. Four possibilities for specification methodologies arise: two each in the Initial and Final algebra paradigms. We demonstrate that the initial/final objects (as appropriate) exist in all four situations. The final part of the paper attempts to explicate the notion of abstractness of ADT's by defining a notion of operational semantics for ADT's, and then studying the relationship between the various algebraic-semantics proposed and the operational semantics. Comments University of Pennsylvania Department of Computer ...

Research paper thumbnail of Data abstraction in programming language semantics

Most modern programming languages allow the user to define abstract data types, thereby creating ... more Most modern programming languages allow the user to define abstract data types, thereby creating an extended language. While the programming language without the definition of ADT's is completely described by its operational semantics, the new constants in the extended language need to be specified in some appropriate formalism. Algebraic equations are one such formalism; such a specification of an ADT constrains the class of valid implementations of the ADT by requiring that the equations be observational equivalences in the extended language. To reason about the extended language it is useful to have a denotational semantics. This thesis studies the denotational semantics of languages with algebraically specified ADT's. For a natural class of models for the extended language we give a necessary and sufficient condition for a model to be computationally adequate with respect to the extended language. This is shown in a variety of language settings--in particular, for a variant of call-by-name PCF, called PCFsbnPCF\sb{n}PCFsbn, and a variant of call-by-value PCF, called PCFsbvsp−PCF\sb{v\sp-}PCFsbvsp to show the general nature of the ideas. We define a class of algebras called reachable, fully abstract algebras, and exhibit a general construction that for a given algebraic specification of an ADT and any fully abstract algebra satisfying the specification constructs a fully abstract model of PCFsbnPCF\sb{n}PCFsbn extended with the ADT. This construction is rather syntactic, and so we consider some special cases where a "semantic" construction of a fully abstract model can be carried out. We then show the construction of two reachable, fully abstract algebras satisfying the specification. Both these algebras have appealing categorical descriptions that can be used to define paradigms of specification semantics, similar to initial and final algebra semantics. For any programming language, there is the problem of reasoning about its models. Mechanization of such reasoning is intractable, in general, and therefore it is useful to consider specific fragments. We consider a fragment of PCFsbnPCF\sb{n}PCFsbn extended with ADT's that consists of simply typed lambda terms with algebraic constants. We study certain natural axiomatizations of specific environment models, which are models of call by name lambda calculi, and derive sufficient conditions for their completeness.

Research paper thumbnail of Lambda Calculus,Conservative Extension and Structural Induction

The issue of whether embedding algebraic theories in higher-order theories such as the simply typ... more The issue of whether embedding algebraic theories in higher-order theories such as the simply typed and polymorphic lambda calculi is of interest in programming language design. The establishment of such a conservative extension result permits modularity in the verification of the correctness of datatype and function implementations. In earlier work [Breazu-Tannen & Meyer 1987a], [Breazu-Tannen & Meyer 1987b] and [Breazu-Tannen 1988], conservative extension results have been obtained for algebraic theories. However, in modelling inductive datatypes, the principle of structural induction needs to be admitted in the inference system, and the question of whether conservative extension holds in the presence of the principle of structural induction needs to be addressed. In this paper we look at the question of whether inductive algebraic theories are conservatively extended when embedded in the simply typed lambda calculus.

Research paper thumbnail of Complexity of algebraic specifications

Lecture Notes in Computer Science, 1990

In the field of algebraic specification, the semantics of an equationally specified datatype is g... more In the field of algebraic specification, the semantics of an equationally specified datatype is given by the initial algebra of the specifications. We show in this paper that in general the theory of the initial algebra of a given set of equations is II 2 0 -complete. The impossibility of complete finite axiomatization of equations as well as inequations true in the initial algebra is therefore established. We, further, establish that the decision problem is, in general, II 1 0 -complete if the equational theory is decidable. We extend the investigation to a certain semantics of parameterized specifications (the so-called free extension functor semantics) that has been proposed in the literature. We present some results characterizing the recursion-theoretic properties of (a) the theory of the free extension algebras of parameter algebras relative to the the theory of the parameter algebras, and (b) the theory of the models of a parameterized specification relative to the theory axiomatized by the specification itself.

Research paper thumbnail of Type Systems in Programming Languages

Optimizations and Machine Code Generation, 2002

Research paper thumbnail of Logical and computational aspects of programming with sets/bags/lists

Lecture Notes in Computer Science, 1991

We study issues that arise in programming with primitive recursion over non-free datatypes such a... more We study issues that arise in programming with primitive recursion over non-free datatypes such as lists, bags and sets. Programs written in this style can lack a meaning in the sense that their outputs may be sensitive to the choice of input expression. We are, thus, naturally led to a set-theoretic denotational semantics with partial functions. We set up a logic for reasoning about the definedness of terms and a deterministic and terminating evaluator. The logic is shown to be sound in the model, and its recursion free fragment is shown to be complete for proving definedness of recursion free programs. The logic is then shown to be as strong as the evaluator, and this implies that the evaluator is compatible with the provable equivalence between different set (or bag, or list) expressions. Oftentimes, the same non-free datatype may have different presentations, and it is not clear a priori whether programming and reasoning with the two presentations are equivalent. We formulate these questions, precisely, in the context of alternative presentations of the list, bag, and set datatypes and study some aspects of these questions. In particular, we establish back-and-forth translations between the two presentations, from which it follows that they are equally expressive, and prove results relating proofs of program properties, in the two presentations.

Research paper thumbnail of Negation as Failure as Resolution

Constraints - An International Journal, 1998

Providing a clean procedural semantics of the “Negation As Failure rule” in Logic Programming has... more Providing a clean procedural semantics of the “Negation As Failure rule” in Logic Programming has been an open problem for some time now. This rule has been treated as a technique in nonmonotonic reasoning, not as a rule in classical logic. This paper contains a demonstration of the negation as failure rule as a resolution procedure in first-order logic. We

Research paper thumbnail of On Adding Algebraic Theories with Induction to Typed Lambda Calculi

Algebraic Methodology and Software Technology, 1991

Research paper thumbnail of Extensions to type systems can preserve operational equivalences

Lecture Notes in Computer Science, 1994

We consider call-by-name, call-by-value, and lazy versions of PCF, and prove, using both syntacti... more We consider call-by-name, call-by-value, and lazy versions of PCF, and prove, using both syntactic and semantic means, that the operational equivalences of the base language are preserved when the language is extended with sum and product types, with polymorphic types, and with recursive types. These theorems show that the type systems of the extended languages are orthogonal to the type systems of the original languages.

Research paper thumbnail of Algebraic reasoning and completeness in typed languages

Proceedings of the 20th ACM SIGPLAN-SIGACT symposium on Principles of programming languages - POPL '93, 1993

Page 1. , Algebraic Reasoning and Completeness in Typed Languages Jon G. Riecke* ATI?T Bell Labor... more Page 1. , Algebraic Reasoning and Completeness in Typed Languages Jon G. Riecke* ATI?T Bell Laboratories Abstract: We consider the following problem in prov-ing observational congruences in functional languages: given ...

Research paper thumbnail of Constructive negation in definite constraint logic programs

Lecture Notes in Computer Science, 1996

Without Abstract

Research paper thumbnail of Completeness theorem for the set-theoretic coproduct model

Research paper thumbnail of Conditions for the completeness of functional and algebraic equational reasoning

Mathematical Structures in Computer Science, 1999

We consider the following question: in the simply-typed λ-calculus with algebraic operations, is ... more We consider the following question: in the simply-typed λ-calculus with algebraic operations, is the set of equations valid in a particular model exactly those provable from (β), (η) and the set of algebraic equations, E, that are valid in the model? We find conditions for determining whether βηE-equational reasoning is complete. We demonstrate the utility of the results by presenting a number of simple corollaries for particular models.

Research paper thumbnail of Equality between Functionals in the Presence of Coproducts

Information and Computation, 2000

We consider the lambda-calculus obtained from the simply-typed calculus by adding products, copro... more We consider the lambda-calculus obtained from the simply-typed calculus by adding products, coproducts, and a terminal type. We prove the following theorem: The equations provable in this calculus are precisely those true in any set-theoretic model with an in nite base type.

Research paper thumbnail of Semantic orthogonality of type disciplines

We consider a version of PCF, and prove, using both syntactic and semantic means, that the op- er... more We consider a version of PCF, and prove, using both syntactic and semantic means, that the op- erational equivalences of the base language are preserved when the language is extended with sum and product types, with polymorphic types, and with recursive types. These theorems show that the additions to the type systems are orthogonal to the original language.

Research paper thumbnail of On extending computational adequacy by data abstraction

Proceedings of the 1992 ACM conference on LISP and functional programming - LFP '92, 1992

Given an abstract data type (ADT), an algebra that specijies it, and an implementation of the dat... more Given an abstract data type (ADT), an algebra that specijies it, and an implementation of the data type in a certain language, if the implementation is "correct", a certain principle of modularity of reasoning holds. Namely, one can safely reason about programs in the language extended by the ADT, by interpreting the ADT operation symbols according to the specification algebra. The main point of this paper is to formalize correctness as a local condition involving only the specification and the implementation and to prove the equivalence of such a condition to the modularity principle. We conduct our study in the context of a language without divergence (in subsection 2.1), and for languages with divergence and general recursion (in subsections 2.2 and 2.3). We also describe a sufficient condition under which, given an implementation, there may be a finite set of observational equivalences which imply the local condition. Further, we illustrate a technique for proving in a practical situation that a given implementation of an abstract data type is correct.

Research paper thumbnail of Data Abstra>ct ion a,nd General Recursion

Existing approaches to semantics of algebraically specified data types such as Initial Algebra Se... more Existing approaches to semantics of algebraically specified data types such as Initial Algebra Semantics and Final Algebra Semantics do not take into account the possibility of general recursion and hence non-termination in the ambient programming language. Any technical development of this problem needs to be in the setting of domain theory. In this paper we present extensions of initial and final algebra semantics to algebras with an underlying domain structure. Four possibilities for specification methodologies arise: two each in the Initial and Final algebra paradigms. We demonstrate that the initial/final objects (as appropriate) exist in all four situations. The final part of the paper attempts to explicate the notion of abstractness of ADT's by defining a notion of operational semantics for ADT's, and then studying the relationship between the

Research paper thumbnail of Data Abstraction and General Recursion

Existing approaches to semantics of algebraically specified data types such as Initial Algebra Se... more Existing approaches to semantics of algebraically specified data types such as Initial Algebra Semantics and Final Algebra Semantics do not take into account the possibility of general recursion and hence nontermination in the ambient programming language. Any technical development of this problem needs to be in the setting of domain theory. In this paper we present extensions of initial and final algebra semantics to algebras with an underlying domain structure. Four possibilities for specification methodologies arise: two each in the Initial and Final algebra paradigms. We demonstrate that the initial/final objects (as appropriate) exist in all four situations. The final part of the paper attempts to explicate the notion of abstractness of ADT's by defining a notion of operational semantics for ADT's, and then studying the relationship between the various algebraic-semantics proposed and the operational semantics. Comments University of Pennsylvania Department of Computer ...

Research paper thumbnail of Data abstraction in programming language semantics

Most modern programming languages allow the user to define abstract data types, thereby creating ... more Most modern programming languages allow the user to define abstract data types, thereby creating an extended language. While the programming language without the definition of ADT's is completely described by its operational semantics, the new constants in the extended language need to be specified in some appropriate formalism. Algebraic equations are one such formalism; such a specification of an ADT constrains the class of valid implementations of the ADT by requiring that the equations be observational equivalences in the extended language. To reason about the extended language it is useful to have a denotational semantics. This thesis studies the denotational semantics of languages with algebraically specified ADT's. For a natural class of models for the extended language we give a necessary and sufficient condition for a model to be computationally adequate with respect to the extended language. This is shown in a variety of language settings--in particular, for a variant of call-by-name PCF, called PCFsbnPCF\sb{n}PCFsbn, and a variant of call-by-value PCF, called PCFsbvsp−PCF\sb{v\sp-}PCFsbvsp to show the general nature of the ideas. We define a class of algebras called reachable, fully abstract algebras, and exhibit a general construction that for a given algebraic specification of an ADT and any fully abstract algebra satisfying the specification constructs a fully abstract model of PCFsbnPCF\sb{n}PCFsbn extended with the ADT. This construction is rather syntactic, and so we consider some special cases where a "semantic" construction of a fully abstract model can be carried out. We then show the construction of two reachable, fully abstract algebras satisfying the specification. Both these algebras have appealing categorical descriptions that can be used to define paradigms of specification semantics, similar to initial and final algebra semantics. For any programming language, there is the problem of reasoning about its models. Mechanization of such reasoning is intractable, in general, and therefore it is useful to consider specific fragments. We consider a fragment of PCFsbnPCF\sb{n}PCFsbn extended with ADT's that consists of simply typed lambda terms with algebraic constants. We study certain natural axiomatizations of specific environment models, which are models of call by name lambda calculi, and derive sufficient conditions for their completeness.

Research paper thumbnail of Lambda Calculus,Conservative Extension and Structural Induction

The issue of whether embedding algebraic theories in higher-order theories such as the simply typ... more The issue of whether embedding algebraic theories in higher-order theories such as the simply typed and polymorphic lambda calculi is of interest in programming language design. The establishment of such a conservative extension result permits modularity in the verification of the correctness of datatype and function implementations. In earlier work [Breazu-Tannen & Meyer 1987a], [Breazu-Tannen & Meyer 1987b] and [Breazu-Tannen 1988], conservative extension results have been obtained for algebraic theories. However, in modelling inductive datatypes, the principle of structural induction needs to be admitted in the inference system, and the question of whether conservative extension holds in the presence of the principle of structural induction needs to be addressed. In this paper we look at the question of whether inductive algebraic theories are conservatively extended when embedded in the simply typed lambda calculus.

Research paper thumbnail of Complexity of algebraic specifications

Lecture Notes in Computer Science, 1990

In the field of algebraic specification, the semantics of an equationally specified datatype is g... more In the field of algebraic specification, the semantics of an equationally specified datatype is given by the initial algebra of the specifications. We show in this paper that in general the theory of the initial algebra of a given set of equations is II 2 0 -complete. The impossibility of complete finite axiomatization of equations as well as inequations true in the initial algebra is therefore established. We, further, establish that the decision problem is, in general, II 1 0 -complete if the equational theory is decidable. We extend the investigation to a certain semantics of parameterized specifications (the so-called free extension functor semantics) that has been proposed in the literature. We present some results characterizing the recursion-theoretic properties of (a) the theory of the free extension algebras of parameter algebras relative to the the theory of the parameter algebras, and (b) the theory of the models of a parameterized specification relative to the theory axiomatized by the specification itself.

Research paper thumbnail of Type Systems in Programming Languages

Optimizations and Machine Code Generation, 2002

Research paper thumbnail of Logical and computational aspects of programming with sets/bags/lists

Lecture Notes in Computer Science, 1991

We study issues that arise in programming with primitive recursion over non-free datatypes such a... more We study issues that arise in programming with primitive recursion over non-free datatypes such as lists, bags and sets. Programs written in this style can lack a meaning in the sense that their outputs may be sensitive to the choice of input expression. We are, thus, naturally led to a set-theoretic denotational semantics with partial functions. We set up a logic for reasoning about the definedness of terms and a deterministic and terminating evaluator. The logic is shown to be sound in the model, and its recursion free fragment is shown to be complete for proving definedness of recursion free programs. The logic is then shown to be as strong as the evaluator, and this implies that the evaluator is compatible with the provable equivalence between different set (or bag, or list) expressions. Oftentimes, the same non-free datatype may have different presentations, and it is not clear a priori whether programming and reasoning with the two presentations are equivalent. We formulate these questions, precisely, in the context of alternative presentations of the list, bag, and set datatypes and study some aspects of these questions. In particular, we establish back-and-forth translations between the two presentations, from which it follows that they are equally expressive, and prove results relating proofs of program properties, in the two presentations.

Research paper thumbnail of Negation as Failure as Resolution

Constraints - An International Journal, 1998

Providing a clean procedural semantics of the “Negation As Failure rule” in Logic Programming has... more Providing a clean procedural semantics of the “Negation As Failure rule” in Logic Programming has been an open problem for some time now. This rule has been treated as a technique in nonmonotonic reasoning, not as a rule in classical logic. This paper contains a demonstration of the negation as failure rule as a resolution procedure in first-order logic. We

Research paper thumbnail of On Adding Algebraic Theories with Induction to Typed Lambda Calculi

Algebraic Methodology and Software Technology, 1991

Research paper thumbnail of Extensions to type systems can preserve operational equivalences

Lecture Notes in Computer Science, 1994

We consider call-by-name, call-by-value, and lazy versions of PCF, and prove, using both syntacti... more We consider call-by-name, call-by-value, and lazy versions of PCF, and prove, using both syntactic and semantic means, that the operational equivalences of the base language are preserved when the language is extended with sum and product types, with polymorphic types, and with recursive types. These theorems show that the type systems of the extended languages are orthogonal to the type systems of the original languages.

Research paper thumbnail of Algebraic reasoning and completeness in typed languages

Proceedings of the 20th ACM SIGPLAN-SIGACT symposium on Principles of programming languages - POPL '93, 1993

Page 1. , Algebraic Reasoning and Completeness in Typed Languages Jon G. Riecke* ATI?T Bell Labor... more Page 1. , Algebraic Reasoning and Completeness in Typed Languages Jon G. Riecke* ATI?T Bell Laboratories Abstract: We consider the following problem in prov-ing observational congruences in functional languages: given ...

Research paper thumbnail of Constructive negation in definite constraint logic programs

Lecture Notes in Computer Science, 1996

Without Abstract

Research paper thumbnail of Completeness theorem for the set-theoretic coproduct model

Research paper thumbnail of Conditions for the completeness of functional and algebraic equational reasoning

Mathematical Structures in Computer Science, 1999

We consider the following question: in the simply-typed λ-calculus with algebraic operations, is ... more We consider the following question: in the simply-typed λ-calculus with algebraic operations, is the set of equations valid in a particular model exactly those provable from (β), (η) and the set of algebraic equations, E, that are valid in the model? We find conditions for determining whether βηE-equational reasoning is complete. We demonstrate the utility of the results by presenting a number of simple corollaries for particular models.

Research paper thumbnail of Equality between Functionals in the Presence of Coproducts

Information and Computation, 2000

We consider the lambda-calculus obtained from the simply-typed calculus by adding products, copro... more We consider the lambda-calculus obtained from the simply-typed calculus by adding products, coproducts, and a terminal type. We prove the following theorem: The equations provable in this calculus are precisely those true in any set-theoretic model with an in nite base type.

Research paper thumbnail of Semantic orthogonality of type disciplines

We consider a version of PCF, and prove, using both syntactic and semantic means, that the op- er... more We consider a version of PCF, and prove, using both syntactic and semantic means, that the op- erational equivalences of the base language are preserved when the language is extended with sum and product types, with polymorphic types, and with recursive types. These theorems show that the additions to the type systems are orthogonal to the original language.

Research paper thumbnail of On extending computational adequacy by data abstraction

Proceedings of the 1992 ACM conference on LISP and functional programming - LFP '92, 1992

Given an abstract data type (ADT), an algebra that specijies it, and an implementation of the dat... more Given an abstract data type (ADT), an algebra that specijies it, and an implementation of the data type in a certain language, if the implementation is "correct", a certain principle of modularity of reasoning holds. Namely, one can safely reason about programs in the language extended by the ADT, by interpreting the ADT operation symbols according to the specification algebra. The main point of this paper is to formalize correctness as a local condition involving only the specification and the implementation and to prove the equivalence of such a condition to the modularity principle. We conduct our study in the context of a language without divergence (in subsection 2.1), and for languages with divergence and general recursion (in subsections 2.2 and 2.3). We also describe a sufficient condition under which, given an implementation, there may be a finite set of observational equivalences which imply the local condition. Further, we illustrate a technique for proving in a practical situation that a given implementation of an abstract data type is correct.