Modular Arithmetic (mod)

If you type in "mod" this will allow you to use the mod function.

So, for example mod(x,2) will show you the remainder of x after dividing by 2.

 

You can also use just numbers with the mod function. For example, mod(6,4) will show the remainder of 6 divided by 4 and output 2 in the expression list as the answer.

 

 

If you click the FUNCTIONS key on the Desmos keypad, you'll find more supported functions in the tabs.

Have more questions? Submit a request

5 Comments

  • 0
    Avatar
    Johnsjac

    by Modular Arithmetic you mean modulo operation, there is a difference:

    https://en.wikipedia.org/wiki/Modulo_operation 

    https://en.wikipedia.org/wiki/Modular_arithmetic

    also, is there a Modular arithmetic in desmos (by the wikipedia's definition)? 

  • 0
    Avatar
    Celestine Aline

  • 0
    Avatar
    Celestine Aline

    thank you

     

  • 0
    Avatar
    701878

    Okay. I have some problems with desmos's mod function. sometimes it will tell me that the mod of the number I plugged in is GREATER than the number I used for the Modifier. Sometimes so large having to using scientific notation. for a modifier of 25.

  • 0
    Avatar
    Johnsjac

    701878, can you show an example? like "3=mod(x,2)", and mod takes 2 values not one, it wont work with one, i say this because: "mod of the number I plugged in"

Please sign in to leave a comment.
Powered by Zendesk