Synaptic plasticity is induced by the influx of calcium ions (Ca2+) through N-methyl-D-aspartate receptors (NMDARs), and the direction and strength of the response depend on the frequency of the synaptic inputs. Recent studies have shown that the direction of synaptic plasticity is also governed by two distinct NMDAR subtypes (NR1/NR2A, NR1/NR2B). How are the different types of regulation (frequency-dependent and receptor-specific) processed simultaneously? To clarify the molecular basis of this dual dependence of synaptic plasticity, we have developed a mathematical model of spatial Ca2+ signaling in a dendritic spine. Our simulations revealed that calmodulin (CaM) activation in the vicinity of NMDARs is strongly affected by the diffusion coefficient of CaM itself, and that this ‘local CaM diffusion system' works as a dual decoder of both the frequency of Ca2+ influxes and their postsynaptic current shapes, generated by two NMDAR subtypes, implying that spatial factors may underlie the complicated regulation scheme of synaptic plasticity.