Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Epistemic Modal Logic Functionality #8

Open
4 tasks done
vezwork opened this issue Nov 17, 2020 · 3 comments
Open
4 tasks done

Add Epistemic Modal Logic Functionality #8

vezwork opened this issue Nov 17, 2020 · 3 comments

Comments

@vezwork
Copy link

vezwork commented Nov 17, 2020

Hi @rkirsling ! I'm a student taking a non-classical logic course at the University of Calgary. During the course, I made great use of the Modal Logic Playground as an intuitive learning method and a place to test formulas while writing assignments.

During the Epistemic Logic section of the course, I wished that there was a version of the Modal Logic Playground that supported multiple agents and the knowledge operator K_a from Epistemic Logic.

Specifically, I'm interested in the Epistemic Modal Logic (ML) logic as defined here: https://plato.stanford.edu/entries/dynamic-epistemic/appendix-A-kripke.html#mjx-eqn-ML%20, but with the knowledge [a] operator notated as K_a instead.

For my final project, I want to contribute the following features to the Modal Logic Playground:

  • Add the ability to interactively define multiple agent’s binary accessibility relations using the existing model editing UI. Each agent will be associated with a different color arrow, with labels for accessibility.

playground

Figure 1: A mock-up of the Epistemic Logic Playground. Notice the buttons for selecting a epistemic agent to modify in the top left, and the different colors of labelled arrows representing different agent’s accessibility relations. See figure 1 below.

  • Add the ability to use the agent knowledge K_a operator in the ”Evaluate Formula” tab. See figure 2 below.

playground_evaluate

Figure 2: Proposed syntax for the textual representation of the Epistemic Logic agent knowledge operator K_a, as well as an explanation of the syntax at the bottom of the image.

  • Add the ability to switch between normal Modal Logic and Epistemic Logic modes. See figure 3 below.

playground_select

Figure 3: Buttons for switching between existing Modal Logic and proposed Epistemic Logic functionality

  • Include information on the site explaining how to use the Epistemic Logic Features.

I've tried to design the features so as not to undermine the ease-of-use of the current system, and hope my changes would be compatible with the existing Modal Logic Playground. I will work over the next two weeks to implement these features in my fork of this repo, and then I will submit a pull request. I would be excited to work with you to merge the changes into this repo if you are interested in doing that.

I've taken a look at http://bl.ocks.org/rkirsling/5001347 and https://github.com/rkirsling/modallogic/blob/master/API-Reference.md and I think it should be reasonably possible, if not a bit tricky, to implement the features.

If you have the time to let me know your thoughts on my proposed features I would greatly appreciate it. Thanks.

@rkirsling
Copy link
Owner

Hey @vezwork, thanks for reaching out! I'm happy that this project was useful to you. 😃

Your idea seems like a well-designed extension and I'd love to see the result! That said, I think you should feel free to take things in your own direction and not feel obliged to make it integrable with what's here—I made this back in 2013 and (aside from some maintenance commits now and again) haven't really changed its functionality since, as I was really just aiming to capture the bite-sized domain of modal propositional logic. In that sense, I'd encourage you to make Epistemic Logic Playground a self-standing thing too!

I don't expect that you'll encounter too much trouble in implementing the logic itself but one tricky thing to note is that D3.js has changed substantially in the years since. I upgraded http://bl.ocks.org/rkirsling/5001347 last year so that it wouldn't go stale as a D3 example, but I didn't upgrade this repo because I felt like it was more important to keep a "finished" project stable as opposed to fresh. Apologies for the frustration that this may incur. 😅

@vezwork
Copy link
Author

vezwork commented Dec 14, 2020

Hey @rkirsling Thanks so much for your input and advice, I took it and went in my own direction. Here's the result: https://vezwork.github.io/modallogic/index.html I didn't run into much trouble implementing anything, the code was easy enough to follow (especially MPL.js) and I'm really happy with how my modifications turned out :) Thanks again for your support.

@rkirsling
Copy link
Owner

Oh wow, it looks really great—I'm thrilled that it worked out well for you! Thanks for sharing the results! 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants