function for simulating
deleted main.py for my purposes
created function to simulate network