An algorithm for non-Born-Oppenheimer quantum mechanical variational calculations of N=1 rotationally excited states of diatomic molecules using all-particle explicitly correlated Gaussian functions