some constant definitions to avoid using magic numbers