The rgsp package provides functionalities to calculate sample number and average sample number for Repetitive Group Sampling Plan Based on Cpk as given in Aslam et al. (2013) (http://dx.doi.org/10.1080/00949655.2012.663374).
Use devtools to install the development version from Github:
if(!require("devtools")) install.packages("devtools") devtools::install_github("myaseen208/rgsp")
This package is free and open source software, licensed under GPL.