added stripe algorithm