Skip to content

Test: add nonzero Mx/My/Mz coverage to nspin=4 Mulliken integration test - #8278

Closed
hujieting wants to merge 1 commit into
deepmodeling:developfrom
hujieting:test-mulliken-spin4-xyz
Closed

hujieting wants to merge 1 commit into
deepmodeling:developfrom
hujieting:test-mulliken-spin4-xyz

Conversation

@hujieting

Copy link
Copy Markdown
Collaborator

Summary

Improve the existing LCAO nspin=4 Mulliken integration test to validate nonzero Mx, My, and Mz components.

The previous test initialized magnetic moments along ±x, resulting in nearly zero My. Consequently, the test could not detect the incorrect My sign fixed in #8250.

Changes

  • Rotate the initial magnetic moments from ±[100] to ±[111] in the existing scf_out_mul_spin4 test.
  • Update mulliken.txt.ref using the corrected ABACUS output.
  • Update magpointgroupref from C_4h to S_6.
  • Keep INPUT, KPT, CI configuration, and the comparison framework unchanged.

Verification

CPU integration test (4 MPI ranks, 1 OpenMP thread):

  • SCF converged in 18 iterations.
  • Total energy: -6263.2934665 eV.
  • Fe1: (Mx, My, Mz) ≈ (+0.6911, +0.6911, +0.6911) μB.
  • Fe2: (Mx, My, Mz) ≈ (-0.6911, -0.6911, -0.6911) μB.
  • Corrected version: integration test passed (exit code 0).
  • Previous version: integration test failed (exit code 1) due to the incorrect My sign.
  • Independent perturbation checks confirmed that the comparison script detects differences in all three magnetization components.

GPU validation has not yet been performed.

Scope

Only three existing integration-test files are modified. No production code, additional test cases, or CI configuration changes are introduced.

Related fix: #8250.

Co-Authored-By: Claude Code <noreply@anthropic.com>
@hujieting hujieting closed this Nov 3, 2026
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.

2 participants