Dihedral Error in adding dihedral parameters and possible solution?

GROMACS version:
GROMACS modification: Yes/No

Hello, I have added some parameters for glycans to CHARMM36 using Charmm-GUI. After the addition, I encountered error messages due to the presence of duplicate lines for dihedral angles, indicating that some parameters in ffbonded.itp were already present in the added parameters. I removed all exactly identical lines. After this operation, I am left with a single error message:

ERROR 1 [file ffbonded.itp, line 16148]: Encountered a second block of parameters for dihedral type 9 for the same atoms, with either different parameters and/or the first block has multiple lines. This is not supported.

The line in question corresponds to this:
CC3162 CC3161 NC2D1 CC2O1 9 0.000000 9.906875 1
CC3162 CC3161 NC2D1 CC2O1 9 180.000000 2.547638 2
CC3162 CC3161 NC2D1 CC2O1 9 180.000000 1.535946 3
CC3162 CC3161 NC2D1 CC2O1 9 180.000000 0.257316 6

I searched in ffbonded.itp and found only one other dihedral with the same atoms, but with the atoms in a different order:
CC2O1 NC2D1 CC3161 CC3162 9 180.000000 2.092000 1

If I change the order of the added atoms to match those of the already existing line, I no longer receive any error messages:
CC2O1 NC2D1 CC3161 CC3162 9 180.000000 2.092000 1
CC2O1 NC2D1 CC3161 CC3162 9 0.000000 9.906875 1
CC2O1 NC2D1 CC3161 CC3162 9 180.000000 2.547638 2
CC2O1 NC2D1 CC3161 CC3162 9 180.000000 1.535946 3
CC2O1 NC2D1 CC3161 CC3162 9 180.000000 0.257316 6

Is this operation correct?
Thanks to everybody in advance

If you’re grouping together dihedrals of type 9 on consecutive lines, you don’t get the error because the terms are being summed. If you got an error before, it means you’re changing an existing part of the force field. Your “solution” is now going to completely change the physics from what you expect, because the two 1-fold terms (which have offsetting phases) will sum to give you a different 1-fold term as part of the cosine series.

Thank you, Prof. Lemkul. I’ll look more into the documentation and my parameters.