Magnesium ions (Mg) in cellular biology are usually in almost all senses opposite to Ca ions, because they are bivalent too, but have greater electronegativity and thus exert greater pull on water molecules, preventing passage through the channel (even though the magnesium itself is smaller). Thus, Mg ions block Ca channels such as (NMDA channels) and have been shown to affect gap junction channels forming electrical synapses.