Theory of hyperfine interactions in potassium and Sc2+ ion: Trends in systems isoelectronic with potassium