2 added 116 characters in body
source | link

Just a different visualization.

    clock[n_, t_, tmax_] := Module[{c},
  c = {Circle[{0, 0}, 1],
    Red,
    Arrow[{{0, 0}, 
      0.7 {Sin[Mod[t, n] 2 Pi/n], Cos[2 Pi  Mod[t, n]/n]}}], {Red,
     ChartElementData[
       "BezelSector"][{{Pi/2 - 2 Pi t/n, Pi/2}, {1, 
        1 + 0.1 Floor[Quotient[t, n]]}}, 0]},
    Black, 
    Table[{Text[ n j/(2 Pi), 0.8 {Sin[j], Cos[j]}], 
      Line[{0.9 {Sin[j], Cos[j]}, {Sin[j], Cos[j]}}]}, {j, 
      0, (n - 1) 2 Pi/n, 2 Pi/n}], Orange,
    Circle[{0, 0}, 1 + 0.1 #] & /@ 
     Range[Floor[Quotient[tmax, n] - 1]]};
  Column[{Graphics[c, ImageSize -> 200],
    Row[Row[Style[#, Bold, Blue, 16, FontFamily -> "Kartika"] & /@ {t, 
       " = "  , 
       Sequence @@ ({#1, "\[Times]", n, "+", #2} & @@ 
          QuotientRemainder[t, n]), " =\[Congruent] ", Mod[t, n], 
       " mod ", n}]
    }, Alignment -> Center, Frame -> All]
  ]

Visualizing (exporting the following as gif):

tab = Table[
   Row[{clock[3, t, 35], clock[5, t, 35], clock[7, t, 35]}], {t, 0, 
    35, 1}];

enter image description here

Note clock 1 and 2 are in phase twice after start (15,30) and clock 2 and 3 only once at 35 ticks.

enter image description here

Just a different visualization.

clock[n_, t_, tmax_] := Module[{c},
  c = {Circle[{0, 0}, 1],
    Red,
    Arrow[{{0, 0}, 
      0.7 {Sin[Mod[t, n] 2 Pi/n], Cos[2 Pi  Mod[t, n]/n]}}], {Red,
     ChartElementData[
       "BezelSector"][{{Pi/2 - 2 Pi t/n, Pi/2}, {1, 
        1 + 0.1 Floor[Quotient[t, n]]}}, 0]},
    Black, 
    Table[{Text[ n j/(2 Pi), 0.8 {Sin[j], Cos[j]}], 
      Line[{0.9 {Sin[j], Cos[j]}, {Sin[j], Cos[j]}}]}, {j, 
      0, (n - 1) 2 Pi/n, 2 Pi/n}], Orange,
    Circle[{0, 0}, 1 + 0.1 #] & /@ 
     Range[Floor[Quotient[tmax, n] - 1]]};
  Column[{Graphics[c, ImageSize -> 200],
    Row[{t, " = "  , 
      Sequence @@ ({#1, "\[Times]", n, "+", #2} & @@ 
         QuotientRemainder[t, n]), " = ", Mod[t, n]}]
    }, Alignment -> Center, Frame -> All]
  ]

Visualizing (exporting the following as gif):

tab = Table[
   Row[{clock[3, t, 35], clock[5, t, 35], clock[7, t, 35]}], {t, 0, 
    35, 1}];

enter image description here

Note clock 1 and 2 are in phase twice after start (15,30) and clock 2 and 3 only once at 35 ticks.

Just a different visualization.

    clock[n_, t_, tmax_] := Module[{c},
  c = {Circle[{0, 0}, 1],
    Red,
    Arrow[{{0, 0}, 
      0.7 {Sin[Mod[t, n] 2 Pi/n], Cos[2 Pi  Mod[t, n]/n]}}], {Red,
     ChartElementData[
       "BezelSector"][{{Pi/2 - 2 Pi t/n, Pi/2}, {1, 
        1 + 0.1 Floor[Quotient[t, n]]}}, 0]},
    Black, 
    Table[{Text[ n j/(2 Pi), 0.8 {Sin[j], Cos[j]}], 
      Line[{0.9 {Sin[j], Cos[j]}, {Sin[j], Cos[j]}}]}, {j, 
      0, (n - 1) 2 Pi/n, 2 Pi/n}], Orange,
    Circle[{0, 0}, 1 + 0.1 #] & /@ 
     Range[Floor[Quotient[tmax, n] - 1]]};
  Column[{Graphics[c, ImageSize -> 200],
    Row[Style[#, Bold, Blue, 16, FontFamily -> "Kartika"] & /@ {t, 
       " = "  , 
       Sequence @@ ({#1, "\[Times]", n, "+", #2} & @@ 
          QuotientRemainder[t, n]), " \[Congruent] ", Mod[t, n], 
       " mod ", n}]
    }, Alignment -> Center, Frame -> All]
  ]

Visualizing (exporting the following as gif):

tab = Table[
   Row[{clock[3, t, 35], clock[5, t, 35], clock[7, t, 35]}], {t, 0, 
    35, 1}];

Note clock 1 and 2 are in phase twice after start (15,30) and clock 2 and 3 only once at 35 ticks.

enter image description here

1
source | link

Just a different visualization.

clock[n_, t_, tmax_] := Module[{c},
  c = {Circle[{0, 0}, 1],
    Red,
    Arrow[{{0, 0}, 
      0.7 {Sin[Mod[t, n] 2 Pi/n], Cos[2 Pi  Mod[t, n]/n]}}], {Red,
     ChartElementData[
       "BezelSector"][{{Pi/2 - 2 Pi t/n, Pi/2}, {1, 
        1 + 0.1 Floor[Quotient[t, n]]}}, 0]},
    Black, 
    Table[{Text[ n j/(2 Pi), 0.8 {Sin[j], Cos[j]}], 
      Line[{0.9 {Sin[j], Cos[j]}, {Sin[j], Cos[j]}}]}, {j, 
      0, (n - 1) 2 Pi/n, 2 Pi/n}], Orange,
    Circle[{0, 0}, 1 + 0.1 #] & /@ 
     Range[Floor[Quotient[tmax, n] - 1]]};
  Column[{Graphics[c, ImageSize -> 200],
    Row[{t, " = "  , 
      Sequence @@ ({#1, "\[Times]", n, "+", #2} & @@ 
         QuotientRemainder[t, n]), " = ", Mod[t, n]}]
    }, Alignment -> Center, Frame -> All]
  ]

Visualizing (exporting the following as gif):

tab = Table[
   Row[{clock[3, t, 35], clock[5, t, 35], clock[7, t, 35]}], {t, 0, 
    35, 1}];

enter image description here

Note clock 1 and 2 are in phase twice after start (15,30) and clock 2 and 3 only once at 35 ticks.