Shouldn't remainder be always less than divisor? [duplicate]
$begingroup$
This question already has an answer here:
Negative quotients and their remainders
1 answer
When dealing with negative modulo such as
7 (mod -5) = -3
is it not necessary that remainder be less than divisor?
I thought modulo should always be positive but the calculator certainly
seem to have no problem with negative modulo.
Does the rules change when dealing with negative modulos?
modular-arithmetic
$endgroup$
marked as duplicate by Bill Dubuque
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 16 '18 at 23:31
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
$begingroup$
This question already has an answer here:
Negative quotients and their remainders
1 answer
When dealing with negative modulo such as
7 (mod -5) = -3
is it not necessary that remainder be less than divisor?
I thought modulo should always be positive but the calculator certainly
seem to have no problem with negative modulo.
Does the rules change when dealing with negative modulos?
modular-arithmetic
$endgroup$
marked as duplicate by Bill Dubuque
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 16 '18 at 23:31
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
$begingroup$
This question already has an answer here:
Negative quotients and their remainders
1 answer
When dealing with negative modulo such as
7 (mod -5) = -3
is it not necessary that remainder be less than divisor?
I thought modulo should always be positive but the calculator certainly
seem to have no problem with negative modulo.
Does the rules change when dealing with negative modulos?
modular-arithmetic
$endgroup$
This question already has an answer here:
Negative quotients and their remainders
1 answer
When dealing with negative modulo such as
7 (mod -5) = -3
is it not necessary that remainder be less than divisor?
I thought modulo should always be positive but the calculator certainly
seem to have no problem with negative modulo.
Does the rules change when dealing with negative modulos?
This question already has an answer here:
Negative quotients and their remainders
1 answer
modular-arithmetic
modular-arithmetic
asked Dec 16 '18 at 22:24
user10344621user10344621
61
61
marked as duplicate by Bill Dubuque
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 16 '18 at 23:31
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
marked as duplicate by Bill Dubuque
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Dec 16 '18 at 23:31
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
In number theory, "$pmod n$" usually isn't an operation. It's most often part of $equiv$. So, for instance, $5equiv 2pmod 3$ doesn't mean that if you apply a "modulus 3 operation" to $5$, you get $2$. It means that $5$ and $2$ are congruent modulo $3$. In other words, that they are some multiple of $3$ apart.
So there is no problem at all with saying $5equiv 8pmod 3$, or $5equiv-4pmod3$.
We also get that $pmod n$ and $pmod{{-}n}$ are equivalent, so we usually don't use negative modulus, because it doesn't give us anything at all.
As for the %
(modulo) operator in programming languages, and on calculators, how they behave with negative numbers is partially up to whoever designed it. There are several equally correct ways to do it. Some may have opinions on which way is the "best", I personally haven't used them enough to make up my mind.
$endgroup$
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
In number theory, "$pmod n$" usually isn't an operation. It's most often part of $equiv$. So, for instance, $5equiv 2pmod 3$ doesn't mean that if you apply a "modulus 3 operation" to $5$, you get $2$. It means that $5$ and $2$ are congruent modulo $3$. In other words, that they are some multiple of $3$ apart.
So there is no problem at all with saying $5equiv 8pmod 3$, or $5equiv-4pmod3$.
We also get that $pmod n$ and $pmod{{-}n}$ are equivalent, so we usually don't use negative modulus, because it doesn't give us anything at all.
As for the %
(modulo) operator in programming languages, and on calculators, how they behave with negative numbers is partially up to whoever designed it. There are several equally correct ways to do it. Some may have opinions on which way is the "best", I personally haven't used them enough to make up my mind.
$endgroup$
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
add a comment |
$begingroup$
In number theory, "$pmod n$" usually isn't an operation. It's most often part of $equiv$. So, for instance, $5equiv 2pmod 3$ doesn't mean that if you apply a "modulus 3 operation" to $5$, you get $2$. It means that $5$ and $2$ are congruent modulo $3$. In other words, that they are some multiple of $3$ apart.
So there is no problem at all with saying $5equiv 8pmod 3$, or $5equiv-4pmod3$.
We also get that $pmod n$ and $pmod{{-}n}$ are equivalent, so we usually don't use negative modulus, because it doesn't give us anything at all.
As for the %
(modulo) operator in programming languages, and on calculators, how they behave with negative numbers is partially up to whoever designed it. There are several equally correct ways to do it. Some may have opinions on which way is the "best", I personally haven't used them enough to make up my mind.
$endgroup$
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
add a comment |
$begingroup$
In number theory, "$pmod n$" usually isn't an operation. It's most often part of $equiv$. So, for instance, $5equiv 2pmod 3$ doesn't mean that if you apply a "modulus 3 operation" to $5$, you get $2$. It means that $5$ and $2$ are congruent modulo $3$. In other words, that they are some multiple of $3$ apart.
So there is no problem at all with saying $5equiv 8pmod 3$, or $5equiv-4pmod3$.
We also get that $pmod n$ and $pmod{{-}n}$ are equivalent, so we usually don't use negative modulus, because it doesn't give us anything at all.
As for the %
(modulo) operator in programming languages, and on calculators, how they behave with negative numbers is partially up to whoever designed it. There are several equally correct ways to do it. Some may have opinions on which way is the "best", I personally haven't used them enough to make up my mind.
$endgroup$
In number theory, "$pmod n$" usually isn't an operation. It's most often part of $equiv$. So, for instance, $5equiv 2pmod 3$ doesn't mean that if you apply a "modulus 3 operation" to $5$, you get $2$. It means that $5$ and $2$ are congruent modulo $3$. In other words, that they are some multiple of $3$ apart.
So there is no problem at all with saying $5equiv 8pmod 3$, or $5equiv-4pmod3$.
We also get that $pmod n$ and $pmod{{-}n}$ are equivalent, so we usually don't use negative modulus, because it doesn't give us anything at all.
As for the %
(modulo) operator in programming languages, and on calculators, how they behave with negative numbers is partially up to whoever designed it. There are several equally correct ways to do it. Some may have opinions on which way is the "best", I personally haven't used them enough to make up my mind.
edited Dec 16 '18 at 23:24
Bill Dubuque
210k29192644
210k29192644
answered Dec 16 '18 at 22:55
ArthurArthur
115k7116198
115k7116198
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
add a comment |
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
The binary operation $bmod$ is also used in mathematics, e.g. $ 10bmod 9 = 1,,$ and that its likely what the OP intended.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:08
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
@BillDubuquque You may be right. I changed the wording slightly to be more correct. Although the binary operation with that notation is not used nearly as often as the relation version to my knowledge. Most of the time I see these kinds of questions on this site, it's due to misunderstanding the relation and thinking it's an operation.
$endgroup$
– Arthur
Dec 16 '18 at 23:12
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
$begingroup$
Often it is merely a misunderstanding of notation - as is likely here.
$endgroup$
– Bill Dubuque
Dec 16 '18 at 23:21
add a comment |