use correct s function