Modeling of contact tracing in social networks