1

Modulus operation with respect to $q\in\mathbb{Z}\setminus{\{0\}}$ (i.e., non-zero integers) is defined as

$$a ~\text{mod}~ q = r,$$

where $r$ is such that $a = nq + r$ for some $n\in\mathbb{Z}$ and $r\in\mathbb{N}_0$. Is there a formal definition of a modulus operation with respect to an arbitrary sequence $(q_1, q_2, \ldots)$ with $q_i \in \mathbb{N}$, defined as

$$ a ~\text{mod}~ (q_1, q_2, \ldots) = r, $$ where $r = a - \sum_{i=1}^{n}q_i$ with $n=\text{sup}\{k : \sum_{i=1}^{k}q_i \le a\}$.

For example $17~\text{mod}~(1, 2, 3, \ldots) = 2$, since $17 = 1 + 2 + 3 + 4 + 5 + \bf{2}$.

I wonder if such operation is being used in scientific literature. If that is the case, is it reffered to as a modulus operation with respect to a sequence or by other term?

minbraz
  • 11
  • 1
    What does $\mathbb Z^{\neq}$ mean? – lulu Mar 29 '21 at 13:36
  • 1
    I don't understand the operation you want. I take it you are looking at finite sequences? But if $n=1$, then your definition does not match the usual definition. – lulu Mar 29 '21 at 13:38
  • To be clear: your definition appears to be just $r=a-\sum q_i$ which isn't terribly interesting. – lulu Mar 29 '21 at 13:40
  • $\mathbb{Z}^{\ne}$ stands for non-zero integers. The sequence can be finite. If $n=1$ we would have $a = q_1 + r$, which satisfy $|r| < |a|$. – minbraz Mar 29 '21 at 13:46
  • Why create new notation without defining it? That seems intentionally confusing. Just write $\mathbb Z - {0}$. – lulu Mar 29 '21 at 13:55
  • More importantly, the point of the congruence $a\equiv r \pmod q$ is not that we can choose an $r$ less than $a$, but that we can choose one less than $q$. – lulu Mar 29 '21 at 13:56
  • Yes, it is my mistake (regarding $|r| < |a|$). I have replaced $\mathbb{Z}^{\ne}$. – minbraz Mar 29 '21 at 14:10

1 Answers1

1

There is no formal notation for such an operation. I develop number theoretic visualizers of integer sequences and we often implement this into our visualizers. Feel free to play around with some of them.