Modeling gas and vapor sorption in a polymer of intrinsic microporosity (PIM-1)