ModuloSteps - Maple Help

Student[Basics]

 ModuloSteps
 generate steps for evaluating modulos

 Calling Sequence ModuloSteps( expr ) ModuloSteps( expr, implicitmultiply = true )

Parameters

 expr - string or expression implicitmultiply - (optional) truefalse output = ... - (optional) option to control the return value displaystyle = ... - (optional) option to control the layout of the steps

Description

 • The ModuloSteps command accepts an expression that is expected to contain modulos and displays the steps required to evaluate each modulo given.
 • If expr is a string, then it is parsed into an expression using InertForm:-Parse so that no automatic simplifications are applied, and thus no steps are missed.
 • The implicitmultiply option is only relevant when expr is a string.  This option is passed directly on to the InertForm:-Parse command and will cause things like 2x to be interpreted as 2*x, but also, xyz to be interpreted as x*y*z.
 • The output and displaystyle options are described in Student:-Basics:-OutputStepsRecord. The return value is controlled by the output option.
 • This function is part of the Student:-Basics package.

Examples

 > $\mathrm{with}\left(\mathrm{Student}:-\mathrm{Basics}\right):$
 > $\mathrm{ModuloSteps}\left("4 mod 7"\right)$
 $\begin{array}{lll}{}& {}& {4}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{7}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}4\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}7\\ {}& {}& {4}\end{array}$ (1)
 > $\mathrm{ModuloSteps}\left("\left(\left(3 + 5 + 6\right) mod 4\right) + \left(\left(5*6*7\right) mod 3\right)"\right)$
 $\begin{array}{lll}{}& {}& \left(\left({3}{+}{5}{+}{6}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\right){+}\left(\left({5}{\cdot }{6}{\cdot }{7}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right)\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({3}{+}{5}{+}{6}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{addition}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a+b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)+\left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({3}{+}\left({5}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\right){+}\left({6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {5}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}5\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}4\\ {}& {}& {1}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({3}{+}{1}{+}\left({6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}6\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}4\\ {}& {}& {2}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({3}{+}{1}{+}{2}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{4}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}6\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}4\\ {}& {}& {2}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& {2}{+}\left({5}{\cdot }{6}{\cdot }{7}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right)\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({5}{\cdot }{6}{\cdot }{7}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{product}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a\cdot b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\cdot \left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left(\left({5}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right){\cdot }\left({6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right){\cdot }\left({7}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {5}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}5\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}3\\ {}& {}& {2}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({2}{\cdot }\left({6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right){\cdot }\left({7}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {6}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}6\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}3\\ {}& {}& {0}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({2}{\cdot }{0}{\cdot }\left({7}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {7}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}7\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}3\\ {}& {}& {1}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({2}{\cdot }{0}{\cdot }{1}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {0}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{3}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}0\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}3\\ {}& {}& {0}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& {2}{+}{0}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {2}\end{array}$ (2)
 > $\mathrm{ModuloSteps}\left("\left(2^200 mod 24\right) + \left(2^201 mod 24\right)"\right)$
 $\begin{array}{lll}{}& {}& \left(\left({{2}}^{{200}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right){+}\left(\left({{2}}^{{201}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{2}}^{{200}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m+c}={\left({a}^{n}\right)}^{m}\cdot {a}^{c}\\ {}& {}& \left({\left({{2}}^{{7}}\right)}^{{28}}{\cdot }{{2}}^{{4}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{128}}^{{28}}{\cdot }{16}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{product}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a\cdot b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\cdot \left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left(\left({{128}}^{{28}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right){\cdot }{16}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{128}}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({128}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {128}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}128\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m+c}={\left({a}^{n}\right)}^{m}\cdot {a}^{c}\\ {}& {}& \left({\left({{8}}^{{3}}\right)}^{{9}}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{512}}^{{9}}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{product}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a\cdot b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\cdot \left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left(\left({{512}}^{{9}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right){\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{512}}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m}={\left({a}^{n}\right)}^{m}\\ {}& {}& \left({\left({{8}}^{{3}}\right)}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{512}}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({512}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({8}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {64}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}64\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {16}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({16}{\cdot }{16}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {256}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}256\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {16}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& {16}{+}\left({{2}}^{{201}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{2}}^{{201}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m+c}={\left({a}^{n}\right)}^{m}\cdot {a}^{c}\\ {}& {}& \left({\left({{2}}^{{7}}\right)}^{{28}}{\cdot }{{2}}^{{5}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{128}}^{{28}}{\cdot }{32}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{product}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a\cdot b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\cdot \left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left(\left({{128}}^{{28}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right){\cdot }\left({32}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{128}}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({128}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {128}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}128\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{28}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m+c}={\left({a}^{n}\right)}^{m}\cdot {a}^{c}\\ {}& {}& \left({\left({{8}}^{{3}}\right)}^{{9}}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{512}}^{{9}}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{product}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\left(a\cdot b\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m=\left(\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\cdot \left(b\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left(\left({{512}}^{{9}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right){\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& \left({{512}}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{9}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply exponent rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{n{}m}={\left({a}^{n}\right)}^{m}\\ {}& {}& \left({\left({{8}}^{{3}}\right)}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({{512}}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Apply the}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{power}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{mod rule:}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}{a}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m={\left(a\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\right)}^{b}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}\mathbf{mod}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}m\\ {}& {}& \left({\left({512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {512}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({{8}}^{{3}}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate inside exponents}\\ {}& {}& \left({512}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}512\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({8}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {64}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}64\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {16}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({16}{\cdot }\left({32}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Examine term}\\ {}& {}& {32}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}32\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& \left({16}{\cdot }{8}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {128}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{mod}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{24}\\ \text{•}& {}& \text{Evaluate modulo, which is the remainder of}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}128\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}\text{divided by}\phantom{\rule[-0.0ex]{1.0thickmathspace}{0.0ex}}24\\ {}& {}& {8}\\ \text{•}& {}& \text{This gives:}\\ {}& {}& {16}{+}{8}\\ \text{•}& {}& \text{Simplify}\\ {}& {}& {24}\end{array}$ (3)

Compatibility

 • The Student:-Basics:-ModuloSteps command was introduced in Maple 2024.