知识卡片

普通读书笔记卡 · 3696

带余除法给唯一标准余数

理解等级:初级

对任意整数a和正整数n,存在唯一整数q、r满足a=qn+r且0≤r。r是a对n的标准余数;即使a为负也必须落在该非负区间,这让模运算有统一代表元。

这张卡片看不懂?

已有反馈 · 0 / 10 条

    还没有人提交反馈。

    在整书笔记中的位置

    原书出处 · 1 处

    • 第31章 数论算法 · 查看原书依据

      Theorem 31.1 (Division theorem) For any integer a and any positive integer n, there exist unique integers q and r such that 0 ≤ r < n and a = qn + r. ▪ The value q = ⌊a/n⌋ is the quotient of the division. The value r = a mod n is the remainder (or residue) of the division, so that n | a if and only if

    参考来源

    - 位置:《算法导论(第4版)》第31章《数论算法》(OEBPS/chapter031.xhtml,文本字符[5000,10000))。 - 结论依据:原文定义整除、素数、余数、同余类和最大公约数,或给出相应定理;公式图已核对。 - 原始内容:Theorem 31.1 (Division theorem) For any integer a and any positive integer n , there exist unique integers q and r such that 0 ≤ r < n and a = qn + r . ▪ The value q = ⌊ a / n ⌋ is the quotient of the division. The value r = a mod n is the remainder (or residue ) of the division, so that n | a if and only if