Skip to content

Fix Gasteiger-Marsili parameters for sp2 carbon in partial_charges() - #1107

Merged
padix-key merged 1 commit into
biotite-dev:mainfrom
padix-key:fix/charges-sp2-carbon-params
Nov 28, 2026
Merged

padix-key merged 1 commit into
biotite-dev:mainfrom
padix-key:fix/charges-sp2-carbon-params

Conversation

@padix-key

@padix-key padix-key commented Nov 26, 2026 •

Copy link
Copy Markdown
Member

partial_charges() used the parameters a=8.79, b=9.18, c=1.88 for sp2 carbon, where b and c were duplicated from the sp3 row. The correct Gasteiger-Marsili parameters are a=8.79, b=9.32, c=1.51.
As the original article is paywalled, I checked the values against two independent implementations: the parameter table in RDKit's Code/GraphMol/PartialCharges/GasteigerParams.cpp lists C sp2 8.79 9.32 1.51, and GasteigerSigmaChi() in Open Babel's src/molchrg.cpp uses the electronegativities 0.98, 8.79 and 19.62 for the anion, neutral atom and cation of sp2 carbon, which is equivalent to b=9.32 and c=1.51. The sp3 and sp carbon rows are consistent with both sources.
The charges of molecules with sp2 carbon atoms change slightly (e.g. third to fourth decimal place for acetone and benzene); the existing tests, including the comparison with the reference values from the article, pass unchanged. Only the partial charges in the docstring example of PDBQTFile had to be updated, as seven of them changed in the last decimal place.

Closes #1065

Authored by Claude

@padix-key
padix-key force-pushed the fix/charges-sp2-carbon-params branch from d3271b1 to b2052b9 Compare November 26, 2026 14:53
@codspeed

codspeed Bot commented Nov 26, 2026

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 111 untouched benchmarks
⏩ 14 skipped benchmarks1


Comparing padix-key:fix/charges-sp2-carbon-params (b2052b9) with main (82c2f2c)

Open in CodSpeed

Footnotes

  1. 14 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

@padix-key
padix-key merged commit 76d0b85 into biotite-dev:main Nov 28, 2026
32 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

partial_charges(): wrong Gasteiger-Marsili parameters for sp2 carbon

1 participant