Zulip Chat Archive

Stream: Equational

Topic: The Finite Magma Game


Eric Taucher (Nov 08 2024 at 20:28):

GitHub project issue 576

FRONT_END: A Sudoku-type game interface for building finite magmas obeying various laws

Since the OpenAI o1-preview model is really good with creating working HTML pages for such did just that.

https://chatgpt.com/share/672e7119-7b44-8013-9b41-4e585cb84db2

The very, very basic HTML page is at GitHub.

There is no copyright or license on the code; it was created by an LLM. :smile:

It is a Self-contained HTML document meaning you do not need to host it on a web server to use.

Now for the ulterior motive. Since I am not a mathematician there are still many holes in my understanding of the entire project; happily making progress in understanding. Instead of me asking lots of basic questions, decided that if I work with those here, we that have holes in our knowledge can learn to understand the project as the game is developed.

Please send your ideas for improvements, problems noticed, etc.

Bruno Le Floch (Nov 14 2024 at 12:52):

It is a nice first version!

Maybe one way to make it more into a game would be to randomly select an interesting (short enough) equation, randomly select a valid example magma, and prefill a few entries of the multiplication table, challenging the user to fill in the rest.

More broadly I think we should think of more ways to do outreach (maybe once the project is done?) as the topic seems understandable, especially with aids such as this game.

Eric Taucher (Nov 14 2024 at 13:07):

Thanks for responding.

Bruno Le Floch said:

It is a nice first version!

I'll let the ChatGPT know. :smile:

Bruno Le Floch said:

select a valid example magma

Can you be more specific, I don't know what you mean by a valid example magma. What criteria makes it valid?


I am also starting a new/different variant for learning implications of two magma expressions. It would check if one implies another. It would show the two expressions as separate grids and then allow one to manipulate the cells and give feedback. Not sure if it will work as I hope.

Bruno Le Floch (Nov 14 2024 at 13:16):

Eric Taucher said:

select a valid example magma

Can you be more specific, I don't know what you mean by a valid example magma. What criteria makes it valid?

I meant that (hidden from the player) there has to be some way to fill in the multiplication table such that the magma ends up obeying the equation. The natural way to ensure that is to start by picking a magma that obeys the equation, then pick at random some entries to show to the player (read-only), and let them try to fill the rest. Hope this clarifies.

Eric Taucher (Nov 16 2024 at 14:10):

Bruno Le Floch said:

fill in the multiplication table such that the magma ends up obeying the equation

Thanks.

After thinking realized this would be a third variation of the game, law variation.

Currently envision three different games or variations.

  1. Basic magma - A basic magma that is not a law/expression, e.g. x = (y ◇ z) ◇ y or implication of two or more laws. This one would be simple enough for a high school student to learn the basics of a magma. (This is what was first posted.)
  2. Law - A magma based on a law/expression, e.g. , x = (y ◇ z) ◇ y
  3. Implication - Shows two magma laws and allows user to try to find a possible implication. Currently don't plan to make this one able to do everything done with this project; will leave the door open for such.

Obviously as the harder the variation the more code behind the scenes is needed. Currently trying to do as much as possible with HTML pages, JavaScript, CSS and not using a Web server but do see that if this is to tie back to the Lean theorems then will need to interface with such if that is possible and practical.

Eric Taucher (Nov 26 2024 at 13:47):

What rules, constraints, properties, or elements should be understood for this project?

Currently, the introduction/tutorial/basic page for the game includes the following concepts:

  • Associativity
  • Commutativity
  • Identity Element
  • Inverse Element
  • Left Cancellation Property
  • Right Cancellation Property
  • Absorbing Element

I’m aware that some of these properties also have left/right variants. If anyone has suggestions for additional concepts to include, your input would be greatly appreciated!

Edward van de Meent (Nov 26 2024 at 13:49):

i'm think Injectivity and Surjectivity are important for some?

Edward van de Meent (Nov 26 2024 at 13:50):

i seem to recall injectivity/surjectivity of multiplication/squaring being a property that gets used in some proofs for finite implications

Eric Taucher (Nov 26 2024 at 14:01):

Here is a screen shot of what the introduction/tutorial/basic page currently looks like

image.png

Eric Taucher (Nov 26 2024 at 19:05):

Created a little animated HTML page that hopefully is intuitive enough for a high school student to understand what left identity means. The demo HTML page is a single HTML file that does not need a web server to host it. Here is a capture video of using it.

Finite Magma Game Left Identity help demo.mp4

Here is the HTML page.

Left identity check visual demonsration.html

If you notice there are two buttons to single step forward and backward so that the user can study the details. If others find this intuitive then I can do more like this but if this is not intuitive will strive for something better. Let me know what you think good or bad. Thanks.

Jose Brox (Nov 26 2024 at 21:35):

Eric Taucher ha dicho:

Created a little animated HTML page that hopefully is intuitive enough for a high school student to understand what left identity means.

I think the animation is great! The position and text of the step backward/forward buttons felt a bit unintuitive to me, just because I'm accustomed to see other kind of buttons, e.g. arrows pointing left/right at the end of the page.

Eric Taucher (Dec 01 2024 at 19:00):

Enhanced the Left Identity Element demo.

  • Option to select size of set from 1 to 6
  • Option to select number of positive results
  • Help page on how to use the demo
  • Now accessible as a Github.io page
  • GitHub project Finite-Magma-Game-Dev

Eric Taucher (Dec 05 2024 at 14:16):

While Sudoku is a static layout of cells, with the Cayley table representation of a binary magma operator giving the user the ability to perform operations on the table would be helpful. For example if the table has an identity element that is not the element in the first row and column, reorienting the table could be of use.

What other types of useful operations might one desire?

Terence Tao (Dec 05 2024 at 15:27):

Duality - transposing the entire magma table - could be a useful or instructive option.

One could also have an option to fill the entire table with a linear model xy=ax+by+c mod Nx \diamond y = ax + by + c \hbox{ mod } N for some specified coefficients a,b,ca,b,c (where NN is the size of the magma), as a lot of interesting examples are of this form.

Terence Tao (Dec 06 2024 at 03:57):

One could enable drag and drop of one row on another (or one column on another) to transpose those two elements of the magma (this would also transpose the columns, and transpose the labels).

Eric Taucher (Dec 06 2024 at 10:04):

Please keep the suggestions coming.

Julian Berman (Dec 07 2024 at 16:50):

Eric Taucher said:

This link twice redirected me to https://pages.github.com/ and I didn't see why for a second -- I think it's because of slightly unideal Zulip behavior (autolinking that) but perhaps good to put that under the link text (so the whole thing links to what is now the link only on the second word).

Also possibly good to put that link as your URL in the GitHub project so someone can get to it from your repo.

Julian Berman (Dec 07 2024 at 16:51):

I haven't played it yet so I have no substantive feedback on the game itself but as an outsider to the project who's keen to know "are there little cool math tidbits that came out of the project that I can learn with little investment" I think the idea is nice!

Eric Taucher (Dec 07 2024 at 21:13):

Julian Berman said:

I think it's because of slightly unideal Zulip behavior (autolinking that)

Yes.

I too had to look at it twice to figure out why when it was created. I thought about converting it to just text, decided to leave it as is as GitHub.io is really nice for hosting these pages and others can learn about GitHub.io pages from the link.

Thanks for noting that for others to see it is a bit confusing.

Eric Taucher (Dec 07 2024 at 21:21):

Julian Berman said:

Also possibly good to put that link as your URL in the GitHub project so someone can get to it from your repo.

If this means that a link to GitHub Pages should be noted in the Finite Magma Game repo readme, then can do. Thanks.

Eric Taucher (Dec 07 2024 at 21:54):

Julian Berman said:

I haven't played it yet

No worries, it is not close to being a game, at least several weeks or more to get to just the Basic magma (ref) to learn the terminology and mechanics of magmas. Hopefully the Basic magma will have established much of the foundational code for the game variations, then it becomes more of a shopping and cooking exercise than doing crop research to see what will take root.

My current focus is on making the concept intuitive and comprehensible for high school students—particularly with my nephews in mind. As someone who isn't a mathematician, I'm deeply engaged in learning numerous technical details while creating the code.


Last updated: May 02 2025 at 03:31 UTC