---
title: kutacc_af2_triangle_multiplication_equation
description: triangle_multiplication的中间步骤，将左右投影通过矩阵相乘生成中间过程参数center_act
url: "https://www.hikunpeng.com/document/detail/zh/kunpenghpcs/hpckit/devg/KunpengHPCKit_developer_135.html"
---

# kutacc_af2_triangle_multiplication_equation

triangle_multiplication的中间步骤，将左右投影通过矩阵相乘生成中间过程参数center_act

#### 接口定义

void kutacc_af2_triangle_multiplication_equation(kutacc_tensor_h center_act, kutacc_tensor_h left_proj_act, kutacc_tensor_h right_proj_act, int64_t n_res_gather, bool is_incoming);


#### 参数

表1 入参定义

| 参数名 | 类型 | 描述 | 输入/输出 |
| --- | --- | --- | --- |
| center\_act | kutacc\_tensor\_h | 中间过程参数 | 输出 |
| left\_proj\_act | kutacc\_tensor\_h | 左投影 | 输入 |
| right\_proj\_act | kutacc\_tensor\_h | 右投影 | 输入 |
| n\_res\_gather | int64\_t | 残基数 | 输入 |
| is\_incoming | bool | 是否为传入方向 | 输入 |


triangle_multiplication的整数参数应满足约束关系:

n_res_gather > 0

单进程情况下n_res必须等于n_res_gather，多进程则不需要满足该条件
