<p>I've hesitated to answer because any answer beyond a simple "yes" could and does fill volumes. Programming language semantics has been profoundly shaped by and in turn has deeply shaped the development of categorical logic, which is the application of algebra to logic.</p>

<p>But I suspect the best way of answering this question is to tell you to go learn <a href="http://wiki.portal.chalmers.se/agda/pmwiki.php">Agda</a> -- the experience of learning to program with dependent types is in large measure coming to grips with how comprehensively algebra pervades computer programming. </p>

CC BY-SA 3.0
2012-08-20T12:38:24.583Z
2012-08-20T12:38:24.583Z
Neel Krishnaswami
<p>Actually there a software for theorical abstract algebra. This soft allow compute some kinds of things like actions groups, Homomorphism etc...
It is Magma: <a href="http://magma.maths.usyd.edu.au/magma/" rel="nofollow">http://magma.maths.usyd.edu.au/magma/</a></p>

<p>I hope this can help you.</p>

CC BY-SA 3.0
2012-08-22T21:17:45.967Z
I am afraid that you have probably misunderstood the question.
Tsuyoshi Ito
CC BY-SA 3.0
2012-08-23T00:08:39.117Z
You think? Well, with Magma you have a library in particular topic about abstract algebra, useful environment for apply in other fields, for example programming language...
Camilo Soler
CC BY-SA 3.0
2012-08-25T17:17:51.203Z
(1) If Magma has a library in particular topic about abstract algebra which is useful to apply to the programming language theory, then you should write about that application.  I do not think that a pointer to Magma is helpful in the context of this question.  (2) To be honest, I doubt that you understand what “programming language theory” means.
Tsuyoshi Ito
CC BY-SA 3.0
2012-08-28T03:31:11.897Z
OK, I just wanted express my idea on another platform that has a library of abstract algebra as the basis (like example) for create or design another "programming language"... is not easy discuss here. I'm sorry if my idea was bad or wrong.
Camilo Soler
CC BY-SA 3.0
2012-08-22T15:26:59.357Z
2012-08-22T15:26:59.357Z
Camilo Soler
<p>Algebra in the classical sense of the word is used in modeling of computational effects as algebraic operations, see for example <a href="http://li2012.univ-mrs.fr/media/talk21/France_lectures_1.pdf">these slides</a> by Gordon Plotkin, or you can read <a href="http://matija.pretnar.info/pdf/handlers-of-algebraic-effects.pdf">real</a> <a href="http://homepages.inf.ed.ac.uk/gdp/publications/Logic_Algebraic_Effects.pdf">papers</a> and <a href="http://matija.pretnar.info/pdf/the-logic-and-handling-of-algebraic-effects.pdf">Ph.D. theses</a>, if you actually meant to ask the question.</p>

<p>And to blow my own horn, have a look at <a href="https://github.com/matijapretnar/eff">Eff</a> and <a href="http://arxiv.org/abs/1203.1539">read about it</a>, a language designed around the idea that computational effects are algebraic operations and that handlers are homomorphisms of algebras.</p>

CC BY-SA 3.0
2012-08-21T11:31:41.340Z
Eff is very cool -- what I understand about deliminted continuations comes mostly from it.
Neel Krishnaswami
CC BY-SA 3.0
2012-08-21T20:56:49.150Z
I am considering a blog reaction to Oleg's "callcc considered harmful" in which I argue that eff is the structured way of working with continuations.
Andrej Bauer
CC BY-SA 3.0
2012-08-22T01:25:33.560Z
Thanks to everyone for answering. I had to accept @AndrejBauer's answer since he implemented his own language as an answer to the question :)
n00b101
CC BY-SA 3.0
2012-08-22T16:28:30.247Z
You've got the order of things wrong there :) It just so happens that Matija and I implemented a language which fits your question.
Andrej Bauer
CC BY-SA 3.0
2012-08-21T05:21:00.350Z
2012-08-21T05:21:00.350Z
Andrej Bauer
<p>Are there any applications of Abstract Algebra to Programming Language Theory? Is there anything that would be useful in language design and compiler implementation?</p>

CC BY-SA 3.0
2012-08-20T03:12:39.927Z
[Uses of algebraic structures in theoretical computer science](http://cstheory.stackexchange.com/questions/10916/uses-of-algebraic-structures-in-theoretical-computer-science)
Sasho Nikolov
CC BY-SA 3.0
2012-08-20T06:19:02.737Z
Have you checked the question linked above? Also [Is Category Theory useful for learning functional programming?](http://cs.stackexchange.com/q/3028/41) and [Functional Programming](http://en.wikipedia.org/wiki/Functional_programming). Do they answer your question?
Kaveh
<pl.programming-languages>
Programming Language Theory and Abstract Algebra
n00b101
# Programming Language Theory and Abstract Algebra

(Asked by: username_0 on 2012-08-20)

Are there any applications of Abstract Algebra to Programming Language Theory? Is there anything that would be useful in language design and compiler implementation?

**Tags:** pl.programming-languages

> **Comments:**
> **username_1**: [Uses of algebraic structures in theoretical computer science](http://cstheory.stackexchange.com/questions/10916/uses-of-algebraic-structures-in-theoretical-computer-science)  
> **username_2**: Have you checked the question linked above? Also [Is Category Theory useful for learning functional programming?](http://cs.stackexchange.com/q/3028/41) and [Functional Programming](http://en.wikipedia.org/wiki/Functional_programming). Do they answer your question?  

---

## 3 answers

### Answer by username_6 on 2012-08-21. Score: 13 | Accepted answer

Algebra in the classical sense of the word is used in modeling of computational effects as algebraic operations, see for example [these slides](http://li2012.univ-mrs.fr/media/talk21/France_lectures_1.pdf) by Gordon Plotkin, or you can read [real](http://matija.pretnar.info/pdf/handlers-of-algebraic-effects.pdf) [papers](http://homepages.inf.ed.ac.uk/gdp/publications/Logic_Algebraic_Effects.pdf) and [Ph.D. theses](http://matija.pretnar.info/pdf/the-logic-and-handling-of-algebraic-effects.pdf), if you actually meant to ask the question.

And to blow my own horn, have a look at [Eff](https://github.com/matijapretnar/eff) and [read about it](http://arxiv.org/abs/1203.1539), a language designed around the idea that computational effects are algebraic operations and that handlers are homomorphisms of algebras.

> **Comments:**
> **username_3**: Eff is very cool -- what I understand about deliminted continuations comes mostly from it.  
> **username_6**: I am considering a blog reaction to Oleg's "callcc considered harmful" in which I argue that eff is the structured way of working with continuations.  
> **username_0**: Thanks to everyone for answering. I had to accept @AndrejBauer's answer since he implemented his own language as an answer to the question :)  
> **username_6**: You've got the order of things wrong there :) It just so happens that Matija and I implemented a language which fits your question.  

---

### Answer by username_3 on 2012-08-20. Score: 9

I've hesitated to answer because any answer beyond a simple "yes" could and does fill volumes. Programming language semantics has been profoundly shaped by and in turn has deeply shaped the development of categorical logic, which is the application of algebra to logic.

But I suspect the best way of answering this question is to tell you to go learn [Agda](http://wiki.portal.chalmers.se/agda/pmwiki.php) -- the experience of learning to program with dependent types is in large measure coming to grips with how comprehensively algebra pervades computer programming.


---

### Answer by username_4 on 2012-08-22. Score: -1

Actually there a software for theorical abstract algebra. This soft allow compute some kinds of things like actions groups, Homomorphism etc...
It is Magma: <http://magma.maths.usyd.edu.au/magma/>

I hope this can help you.

> **Comments:**
> **username_5**: I am afraid that you have probably misunderstood the question.  
> **username_4**: You think? Well, with Magma you have a library in particular topic about abstract algebra, useful environment for apply in other fields, for example programming language...  
> **username_5**: (1) If Magma has a library in particular topic about abstract algebra which is useful to apply to the programming language theory, then you should write about that application.  I do not think that a pointer to Magma is helpful in the context of this question.  (2) To be honest, I doubt that you understand what “programming language theory” means.  
> **username_4**: OK, I just wanted express my idea on another platform that has a library of abstract algebra as the basis (like example) for create or design another "programming language"... is not easy discuss here. I'm sorry if my idea was bad or wrong.  

---

