|
LMMP 4.3.0
Lamina High-Precision Arithmetic Library
|
函数 | |
| mp_size_t | lmmp_gcd_ (mp_ptr dst, mp_srcptr up, mp_size_t un, mp_srcptr vp, mp_size_t vn) |
| Copyright (C) 2026 HJimmyK (Jericho Knox) | |
Copyright (C) 2026 HJimmyK (Jericho Knox)
计算两个无符号整数的最大公约数(通用分发入口)
This file is part of LMMP.
LMMP is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library. If not, see https://www.gnu.org/licenses/.
SPDX-License-Identifier: LGPL-3.0-or-later
Copyright (C) 2026 HJimmyK (Jericho Knox)
| dst | 结果指针(长度至少为 min(un,vn)) |
| up | 第一个无符号整数指针 |
| un | 第一个无符号整数的 limb 长度 |
| vp | 第二个无符号整数指针 |
| vn | 第二个无符号整数的 limb 长度 |
引用了 GCD_HGCD_THRESHOLD, lmmp_gcd_(), lmmp_gcd_11_(), lmmp_gcd_1_(), lmmp_gcd_22_(), lmmp_gcd_2_(), lmmp_gcd_hgcd_(), lmmp_gcd_lehmer_(), lmmp_param_assert , 以及 LMMP_SWAP.
被这些函数引用 lmmp_gcd_(), small_factor_q(), TEST_CASE(), TEST_CASE(), TEST_CASE() , 以及 TEST_CASE().