---
title: KesSolverSetThreshold
description: "KesReturnCode KesSolverSetThreshold(KesSolver solver, double threshold);"
url: https://www.hikunpeng.com/document/detail/zh/hpchistory/hpckit/develop2400/kunpengaccel_kml_0962.html
sourcePath: /source/zh/hpchistory/hpckit/develop2400/kunpengaccel_kml_0962.html
indexId: a3f5170a050c46fa1ec18e22ced68fab02284c55ef5cda84ec1c4952c64a699567
---
# KesSolverSetThreshold

#### 接口定义

KesReturnCode KesSolverSetThreshold(KesSolver solver, double threshold);


#### 接口说明

设置收敛误差，默认值为0.000001。


#### 参数

| 参数名 | 类型 | 描述 | 输入/输出 |
| --- | --- | --- | --- |
| solver | KesSolver | 求解器句柄，不能为空指针。 | 输入/输出 |
| threshold | double | 收敛误差。 | 输入 |
