|
LMMP 4.3.0
Lamina High-Precision Arithmetic Library
|
#include "lmmpn/toom_interp.h"函数 | |
| void | lmmp_toom_couple_handling_ (mp_ptr pp, mp_size_t n, mp_ptr np, int nsign, mp_size_t off, int ps, int ns) |
| Copyright (C) 2026 HJimmyK (Jericho Knox) | |
| void lmmp_toom_couple_handling_ | ( | mp_ptr | pp, |
| mp_size_t | n, | ||
| mp_ptr | np, | ||
| int | nsign, | ||
| mp_size_t | off, | ||
| int | ps, | ||
| int | ns ) |
Copyright (C) 2026 HJimmyK (Jericho Knox)
Toom ± 点对配对混合:一次完成和/差半边的右移缩放与重叠拼回 (toom6h/8h 各评估点对的两个 (n+1) 位乘积的后处理) 输入 [pp,n] 与 (nsign ?
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)
-[np,n] : [np,n]),计算: [np,n] <- ([pp,n]+[np,n])/2^(ns+1)(和半边,供奇系数插值) [pp,n] <- ([pp,n]-[np,n])/2^(ps+1)(差半边,供偶系数) 最后 {pp,n+off} <- {pp,n} + {np,n}*B^off
| pp | 输入/输出:正点值乘积(容量 n+off+1 limbs) |
| n | 有效数据长度 |
| np | 输入/输出:负点值乘积(容量 n limbs) |
| nsign | np 的符号(非 0 表示 np 存的是负值) |
| off | 拼回偏移(limb 数,0<=off<n) |
| ps | 和半边附加右移位数 |
| ns | 差半边附加右移位数 |
在文件 mul_toom_couple.c 第 26 行定义.
引用了 lmmp_add_1_(), lmmp_add_n_(), lmmp_debug_assert, lmmp_param_assert, lmmp_shr1add_n_(), lmmp_shr1sub_n_(), lmmp_shr_(), lmmp_sub_n_(), lmmp_toom_couple_handling_() , 以及 n.
被这些函数引用 lmmp_mul_toom6h_(), lmmp_mul_toom8h_(), lmmp_sqr_toom6_(), lmmp_sqr_toom8_() , 以及 lmmp_toom_couple_handling_().