# Check for Correct Equation In Table

I am figuring out how to let my students know the equation they have typed in is correct. I have figured out how to create the code for exact numerical values. However, I have been unable to figure out text input with exponents. When they type their equation, I want them to get a message that says they are correct when they put in y=5(1.4)^x. If you could also let me know how to include fractions in the correct values, if necessary. Thanks!

My coding so far:
cellContent(1,2): when input9.cellContent(1,1)= “y=5(1.4)^x” or
input9.cellContent(1,1)= “y=5(1.4)^x” “” otherwise “

You appear to be trying to just match the latex. You should use a backtick (next to the 1 on your keyboard) instead of quotations. Also, for exponents, surround with curly braces for best results:

 y=5(1.4)^{x}


Not sure why the or statement, since both parts look the same. You may also want to look into evaluative methods of checking expressions and equations for something more robust than latex matching.

Thank you so much!!! I was trying to copy codes from other activities already created. This worked for all of my equations except for ones with fractions. I am trying to put in y=40(1/3)^x. I know it has to do with the way I put the fraction in.

If you type your target equation into the desmos calculator, then copy-paste that into computation layer, it should format it the way you want. Fractions are coded like so:

\frac{1}{3}


Here are some activities I put together that check exponential equations for correctness.