Valence partitioning for diradicals and zwitterions