RSGDX program and its test suite