# B Equation with modulus (1 Viewer)

### Users Who Are Viewing This Thread (Users: 0, Guests: 1)

#### hugo_faurand

Hello everyone!
I'd like to know if it's possible to solve an equation with a modulus like this one :

$$( \frac{200}{15x}) mod 2 = 0$$

Regards!

#### andrewkirk

Homework Helper
Gold Member
Sure. It means that $\frac{200}{15\,x}=2k$ for some nonzero integer $k$. For each $k$ there will be a different solution $x$.

#### PeroK

Homework Helper
Gold Member
2018 Award
Mmmmmh. I don't really understand. What is k? Does it mean that the solution is a kind of pair like in a 2 unknown equation?
Is $x$ supposed to be an integer? Or any real number?

#### hugo_faurand

Is $x$ supposed to be an integer? Or any real number?
Normally it's an integer. Does it change something to solve the equation?

#### PeroK

Homework Helper
Gold Member
2018 Award
Normally it's an integer. Does it change something to solve the equation?
Have you looked for integer solutions?

Hint: 15 has a factor of 3.

#### mfb

Mentor
z mod 2 = 0 means z is an integer multiple of 2. In other words, there has to be an integer k such that z=2k. That's where the expression in post 2 comes from.

If x is an integer, then 200/(15x) won't be one.

#### Martin Rattigan

The solution is $x=1\mod 2$. If $x=0\mod 2$ then $\frac{200}{15x}$ is undefined$\mod 2$ (so not a solution according to Russell's theory of definite descriptions).

This assumes you are looking for solutions in the field of integers $\mod 2$, so there are but two possible solutions. The equation reduces to $$\frac{0}{x}=0\mod 2$$As in any field any nonzero element is a solution of this equation.

Last edited:

#### mfb

Mentor
@Martin Rattiqan: None of that is right.
As you can easily verify, x=1 for example is not a solution, but you claim it would be.
200/(15x) is well-defined for x=2 and you can consider 200/(15x) mod 2 while x=0 mod 2 is satisfied.
This assumes you are looking for solutions in the field of integers mod 2
Why would you assume that?
The equation reduces to
You can't reduce equations like that.

#### Stephen Tashi

@Martin Rattiqan: None of that is right.
It's not right according to the interpretation that @hugo_faurand probaby has in mind, where mod 2 arithmetic is considered an algorithm performed on the integers.

However, from the more advanced viewpoint of talking about $\mathbb{Z}/(2 \mathbb{Z})$ we have that the notation "200" represents the coset $[200]= [0] = \{...-4,-2,0,2,4,...\}$ and it is indeed true that $[200]/([15][x] )= [0]/([1] [x])$. Whether to call that "reduction" could be debated. It's also true that letting $[x] = [1]$ gives us $[0]/([1][1]) = [0]/[1] = [0][1]^{-1} = [0][1] = [0]$.

So if @Martin Rattigan errs ,he errs only in taking a more advanced viewpoint that the original poster.

#### hugo_faurand

Mmmmh it's a quite interesting debate. But to give a context I'd like to know if I can have an expression of x with this equation :
$$\frac{a}{bx} \mod 2 = 0$$
In case of I'm not clear enough, I want an equation which looks like that :
$$x = \text{something with b and a }$$

#### Stephen Tashi

Mmmmh it's a quite interesting debate.
The only subject for debate is the meaning of your question.
But to give a context I'd like to know if I can have an expression of x with this equation :
$$\frac{a}{bx} \mod 2 = 0$$
Notation, by itself, does not specify a context.

Instead of "have an expression of x", you probably mean to ask whether a certain equation "has a solution for x".

Defining the meaning of your notation "$\frac{a}{bx} \mod 2 = 0$" requires some words.

For example, what is your interpretation of "$\mod 2$"? By some interpretations of "$\mod 2$" it is correct to write "$4 = 0 \mod 2$" because, in that context, the relation "=" is not the ordinary equivalence relation for numbers.

A different interpretation is that "$\frac{c}{d} \mod 2$" denotes an operation on two numbers $c,d$ that is performed by taking the positive remainder after c is divided by d. That interpretation is not specific until you define the set of numbers that may be operated upon. For example, must c and d be integers?

If you don't know the meaning of your notation "$\frac{a}{bx} \mod 2$", perhaps you can tell us where you saw this notation. What book? What course?

#### mfb

Mentor
Assuming "mod 2" as operator does what e.g. computers would do (find a value from 0 inclusive to 2 exclusive that differs by an integer multiple of 2 from the input), see post 2: There is a k such that a/(bx) = 2k. Now we can solve for x in the usual way: x=a/(2bk). Every integer k apart from zero will lead to a solution for x. As an example, k=2 leads to x=a/(4b), if we plug that into the original equation we get a/(b*(a/4b) mod 2 = 4 mod 2 = 0 on the left hand side, which is indeed equal to zero.

#### hugo_faurand

The only subject for debate is the meaning of your question.

Notation, by itself, does not specify a context.

Instead of "have an expression of x", you probably mean to ask whether a certain equation "has a solution for x".

Defining the meaning of your notation "$\frac{a}{bx} \mod 2 = 0$" requires some words.

For example, what is your interpretation of "$\mod 2$"? By some interpretations of "$\mod 2$" it is correct to write "$4 = 0 \mod 2$" because, in that context, the relation "=" is not the ordinary equivalence relation for numbers.

A different interpretation is that "$\frac{c}{d} \mod 2$" denotes an operation on two numbers $c,d$ that is performed by taking the positive remainder after c is divided by d. That interpretation is not specific until you define the set of numbers that may be operated upon. For example, must c and d be integers?

If you don't know the meaning of your notation "$\frac{a}{bx} \mod 2$", perhaps you can tell us where you saw this notation. What book? What course?
For me "x mod 2" is like dividing x by 2 and take the rest of the division.

Assuming "mod 2" as operator does what e.g. computers would do (find a value from 0 inclusive to 2 exclusive that differs by an integer multiple of 2 from the input), see post 2: There is a k such that a/(bx) = 2k. Now we can solve for x in the usual way: x=a/(2bk). Every integer k apart from zero will lead to a solution for x. As an example, k=2 leads to x=a/(4b), if we plug that into the original equation we get a/(b*(a/4b) mod 2 = 4 mod 2 = 0 on the left hand side, which is indeed equal to zero.

Why a value from 0 inclusive to 2 exclusive ?

#### mfb

Mentor
Why a value from 0 inclusive to 2 exclusive ?
That's what computers will usually do. Here is python, for example:

>>> 2%2
0
>>> 3.141%2
1.141
>>> -1%2
1
>>> -5.5%2
0.5

#### hugo_faurand

That's what computers will usually do. Here is python, for example:

>>> 2%2
0
>>> 3.141%2
1.141
>>> -1%2
1
>>> -5.5%2
0.5
OK but now I have two unknowns k and x .SO How can I solve it ?

#### mfb

Mentor
See above. There are many values of x that satisfy the equation, one for every k.

#### Martin Rattigan

That's what computers will usually do. Here is python, for example:

>>> 2%2
0
>>> 3.141%2
1.141
>>> -1%2
1
>>> -5.5%2
0.5
But if you run

<p id="a">
<script>
function m2(exp){document.getElementById("a").innerText += (exp)%2+"\n"}
m2(2)
m2(3.141)
m2(-1)
m2(-5.5)
m2(200/(15*1))
</script>

in e.g. Chrome, javascript gives:

0
1.141
-1
-1.5
1.333333333333334

You can't rely on different computer programs to give the same answers.

Given that this is a mathematics forum rather than a programming forum I expect OP would prefer an answer conforming with generally accepted mathematics.

In this case only the odd numbered elements in my list are defined because the even numbered elements have denominators which are not relatively prime to 2.

Javascript gets the wrong answer for my fifth - it should be 0 (or rather I ask it to get the wrong answer because the "/" is interpreted as floating point division - there is no native javascript division$\mod n$). Both python and Javascript get the first and third right. The answers are the same because $1=-1\mod 2$.

Last edited:

#### Martin Rattigan

See above. There are many values of x that satisfy the equation, one for every k.
But really the whole usefulness of arithmetic modulo $n$ is that the canonical isomorphism from $\mathbb{Z}$ to $\mathbb{Z}/n\mathbb{Z}$ allows you to ignore the $k$s. There is only one value$\mod 2$ that satisfies OP's equation as stated in my original post.

Last edited:

#### Martin Rattigan

Assuming "mod 2" as operator does what e.g. computers would do (find a value from 0 inclusive to 2 exclusive that differs by an integer multiple of 2 from the input), see post 2: There is a k such that a/(bx) = 2k. Now we can solve for x in the usual way: x=a/(2bk). Every integer k apart from zero will lead to a solution for x. As an example, k=2 leads to x=a/(4b), if we plug that into the original equation we get a/(b*(a/4b) mod 2 = 4 mod 2 = 0 on the left hand side, which is indeed equal to zero.
The problem with the operator you describe is that its not very useful mathematically if it's applied to the real numbers, because it doesn't necessarily respect arithmetic in the reals. E.g.

<p id="a">
<script>
function m2(exp){document.getElementById("a").innerText += (exp)%2+"\n"}
m2(Math.sqrt(5)*Math.sqrt(5))
m2((Math.sqrt(5)%2)*(Math.sqrt(5)%2))
</script>

when run in Chrome gives

1.0000000000000009
0.055728090000841266

For any ring $R$ there is a canonical homomorphism from $R$ to $R/nR$ (where $nR$ is defined as $\{r+r+\ldots+r\ (n\text{ times}):r \in R\}$, which might be described as a$\mod n$ operator (and, of course, respects the arithmetic in $R$), but if $R$ is a field then the quotient is either the single element ring or the field you started with depending on the field's characteristic, ergo not much use. The operator would not be the one you described in the case $R=\mathbb{R}$ because in that case the ring of even integers is not the ideal $2\mathbb{R}$.

The $\mod n$ notation in mathematics is usually used when $R$ is $\mathbb{Z}$ or possibly $\{i/j:i,j\in \mathbb{Z}\text{ and }(j,n)=1\}.$

Last edited:

### The Physics Forums Way

We Value Quality
• Topics based on mainstream science
• Proper English grammar and spelling
We Value Civility
• Positive and compassionate attitudes
• Patience while debating
We Value Productivity
• Disciplined to remain on-topic
• Recognition of own weaknesses
• Solo and co-op problem solving