Implementing suggestions

Applying suggestions of issue #4 and applying changes to this static
version and be ready to use is a template for the dynamic version