Latex Code to Create Math Matching Game - PhysicsForums

  • Context: LaTeX 
  • Thread starter Thread starter karush
  • Start date Start date
  • Tags Tags
    Game
Click For Summary
SUMMARY

The forum discussion focuses on creating a math matching game using LaTeX, specifically utilizing the TikZ package for visual representation. The provided code snippet demonstrates how to construct a matrix of mathematical expressions and includes a method for drawing connections between selected items. Users express interest in developing a mobile-friendly version of the game that incorporates branding for MHB. The discussion highlights the need for functionality that allows users to select buttons and receive feedback on their choices.

PREREQUISITES
  • Familiarity with LaTeX typesetting
  • Understanding of TikZ package for graphical elements
  • Basic knowledge of matrix structures in LaTeX
  • Experience with user interaction design in educational tools
NEXT STEPS
  • Explore advanced TikZ features for interactive elements in LaTeX
  • Research mobile app development frameworks suitable for educational games
  • Learn about LaTeX packages for user input handling
  • Investigate methods for integrating branding into educational applications
USEFUL FOR

Educators, game developers, and anyone interested in creating interactive educational tools using LaTeX and TikZ for mobile platforms.

karush
Gold Member
MHB
Messages
3,240
Reaction score
5
https://www.physicsforums.com/attachments/8765

ok I am trying to find out what the latex code is to do this.
whether or not it could be used here I do not know
but trying to see if a cell phone version of it could be created.

I think MHB could be advertised a lot if students could get these on their cell phone with MHB link and logo on it

Just a thot
:cool:
 
Physics news on Phys.org
Well, we can do for instance:
\begin{tikzpicture}[every node/.style={outer sep=1pt}]
%preamble \usepackage{amsmath,amssymb}
\usetikzlibrary{matrix}

\matrix (m) [matrix of math nodes,nodes in empty cells,
column 1/.style={nodes={anchor=east}},
column 2/.style={nodes={circle,draw}},
column 3/.style={nodes={circle,draw}},
column 4/.style={nodes={anchor=west}},
]{
(a+b)^2 &[2mm] &[1cm] &[2mm] \cos(2\theta)\\
(a-b)^2 & & & -\frac{1}{12}\\
\frac{n!}{k!(n-k)!} & & & 1\\
\cos^2\theta-\sin^2\theta & & & a^2+2ab+b^2\\
\cos^2\theta+\sin^2\theta & & & \binom{n}{k}\\
\sum_{n=1}^\infty n & & & a^2-2ab+b^2\\
};

\draw[blue,ultra thick]
(m-3-2) -- (m-5-3)
(m-6-2) -- (m-2-3)
;
\end{tikzpicture}

Click on it to see the latex code.
 
ok, but I think I know that much, that was just a sample output.

need to know how you code this so when 2 of the buttons selected are correct it will draw a line connecting them. if incorrect it will display message.

I've seen language matching apps but they are quite sloppy

how do you do a select button in latex
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 16 ·
Replies
16
Views
4K
  • · Replies 1 ·
Replies
1
Views
4K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K