Building a model for an encryption system based on modular arithmetic