Skip to main content

Type Checking by Domain Analysis in Ampersand

  • Conference paper
  • First Online:
Relational and Algebraic Methods in Computer Science (RAMICS 2015)

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

Abstract

In the process of incorporating subtyping in relation algebra, an algorithm was found to derive the subtyping relation from the program to be checked. By using domain analysis rather than type inference, this algorithm offers an attractive visualization of the type derivation process. This visualization can be used as a graphical proof that the type system has assigned types correctly. An implementation is linked to in this paper, written in Haskell. The algorithm has been tried and tested in Ampersand, a language that uses relation algebra for the purpose of designing information systems.

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

Access this chapter

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

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. The Business Rules Group: Business rules manifesto – the principles of rule independence (2003). http://www.BusinessRulesGroup.org

  2. Michels, G., Joosten, S., van der Woude, J., Joosten, S.: Ampersand: Applying relation algebra in practice. In: de Swart, H. (ed.) RAMICS 2011. LNCS, vol. 6663, pp. 280–293. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  3. Maddux, R.: Relation Algebras. Studies in Logic and the Foundations of Mathematics, vol. 150. Elsevier Science (2006)

    Google Scholar 

  4. van der Woude, J., Joosten, S.: Relational heterogeneity relaxed by subtyping. In: de Swart, H. (ed.) RAMICS 2011. LNCS, vol. 6663, pp. 347–361. Springer, Heidelberg (2011)

    Chapter  Google Scholar 

  5. Milner, R.: A theory of type polymorphism in programming. Journal of Computer and System Sciences 17, 348–375 (1978)

    Article  MathSciNet  MATH  Google Scholar 

  6. Marlow, S., Wadler, P.: A practical subtyping system for erlang. SIGPLAN Not. 32, 136–149 (1997)

    Article  Google Scholar 

  7. Liskov, B.H., Wing, J.M.: A behavioral notion of subtyping. ACM Transactions on Programming Languages and Systems (TOPLAS) 16, 1811–1841 (1994)

    Article  Google Scholar 

  8. Mitchell, J.C.: Type inference with simple subtypes. Journal of Functional Programming 1, 245–285 (1991)

    Article  MathSciNet  MATH  Google Scholar 

  9. Amadio, R.M., Cardelli, L.: Subtyping recursive types. ACM Transactions on Programming Languages and Systems (TOPLAS) 15, 575–631 (1993)

    Article  Google Scholar 

  10. Tiuryn, J., Urzyczyn, P.: The subtyping problem for second-order types is undecidable. In: IEEE Computer Society Symposium on Logic in Computer Science, pp. 74–74 (1996)

    Google Scholar 

  11. Wells, J.B.: The undecidability of mitchell’s subtyping relationship. Technical report, Boston University Computer Science Department (1995)

    Google Scholar 

  12. Lindahl, T., Sagonas, K.: Practical type inference based on success typings. In: Proceedings of the 8th ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming, pp. 167–178. ACM (2006)

    Google Scholar 

  13. Tomás, D., Vicedo, J.L.: Minimally supervised question classification on fine-grained taxonomies. Knowledge and Information Systems 36, 303–334 (2013)

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Stef M. M. Joosten .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2015 Springer International Publishing Switzerland

About this paper

Cite this paper

Joosten, S.M.M., Joosten, S.J.C. (2015). Type Checking by Domain Analysis in Ampersand. In: Kahl, W., Winter, M., Oliveira, J. (eds) Relational and Algebraic Methods in Computer Science. RAMICS 2015. Lecture Notes in Computer Science(), vol 9348. Springer, Cham. https://doi.org/10.1007/978-3-319-24704-5_14

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-24704-5_14

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-24703-8

  • Online ISBN: 978-3-319-24704-5

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics