Hi thanks for the query.
The complaints of shoulder pain
and the tilted rib could not be correlated. Lying on your back with legs on chair is comfortable to your lower back pain
and not to the shoulder pain. i suggest you to visit local orthopaedician and get his opinion regarding the shoulder pain. There are different exercise for shoulder pain which can be learnt after the problem is identified.