added gcd features to improve efficiency of app