# Inconsistent minimum value for scalingModSize

**URL:** <https://openfhe.discourse.group/t/inconsistent-minimum-value-for-scalingmodsize/2278>\
**Category:** Library Questions\
**Created:** [February 20, 2026, 6:46am UTC](https://openfhe.discourse.group/t/inconsistent-minimum-value-for-scalingmodsize/2278 "2026-02-20T06:46:12Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![hyerinpark](https://avatars.discourse-cdn.com/v4/letter/h/bc79bd/32.png) [@hyerinpark](https://openfhe.discourse.group/u/hyerinpark)\
**Post date:** [February 20, 2026, 6:46am UTC](https://openfhe.discourse.group/t/inconsistent-minimum-value-for-scalingmodsize/2278/1 "2026-02-20T06:46:12Z")

</div>

Hello,

I noticed a potential inconsistency regarding the minimum allowed value of `scalingModSize`.

In [commit 2052e64](https://github.com/openfheorg/openfhe-development/commit/2052e644d0beae70ecf9604ad18537a951539926), the following condition checking and exception message was introduced in `src/pke/lib/scheme/gen-cryptocontext-params-validation.cpp:`

```cpp
if (COMPOSITESCALING_MAX_MODULUS_SIZE <= parameters.GetScalingModSize() || 15 > parameters.GetScalingModSize()) {
  OPENFHE_THROW("scalingModSize should be greater than 15 and less than " + 
                std::to_string(COMPOSITESCALING_MAX_MODULUS_SIZE));
}

```

The message implies that `scalingModSize` must be greater than 15 (i.e., minimum 16), while the condition is considering 15 valid (i.e., the actual minimal is 15).

However, in `src/pke/include/schemerns/rns-parametergeneration.h`, the minimum value still appears to be set to 14:

```cpp
protected:
    enum DCRT_MODULUS {
        DEFAULT_EXTRA_MOD_SIZE = 20,
        MIN_SIZE = 14,
        MAX_SIZE = 60,
    };

```

Should these constraints be unified?

It would be helpful to clarify which lower bound is intended by design and make the parameter generation logic, runtime check, and exception message consistent.

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![ypolyakov](https://yyz1.discourse-cdn.com/flex031/user_avatar/openfhe.discourse.group/ypolyakov/32/47_2.png) [@ypolyakov](https://openfhe.discourse.group/u/ypolyakov)\
**Post date:** [March 2, 2026, 12:25pm UTC](https://openfhe.discourse.group/t/inconsistent-minimum-value-for-scalingmodsize/2278/2 "2026-03-02T12:25:26Z")

</div>

Thank you for reporting it. I’ve created a corresponding issue: [Inconsistency in the minimum value of scaling mod size for CKKS · Issue #1133 · openfheorg/openfhe-development · GitHub](https://github.com/openfheorg/openfhe-development/issues/1133)
