Added namespace and functions