A simple analytical relation of form {\alpha} = 2 {\kappa} -1 between the magnetic energy spectral exponent {\alpha} of the turbulent magnetic field in the solar photosphere and its magnetic flux cancellation exponent {\kappa}, valid under certain restrictive assumptions, is tested and extended outside its range of validity in a series of Monte Carlo simulations. In these numerical tests artificial "magnetograms" are constructed in 1D and 2D by superposing a discrete set of Fourier modes of the magnetic field distribution with amplitudes following a power law spectrum and measuring the cancellation function on these simulated magnetograms. Our results confirm the validity of the analytical relation and extend it to the domain {\alpha} < -1 where {\kappa} ---> 0 as {\alpha} ---> - infinity. The observationally derived upper limit of 0.38 on {\kappa} implies {\alpha} < -0.24 in the granular size range, apparently at odds with a small scale dynamo driven in the inertial range.