A model and a technique for studies of friendship