In Triangle ABC, the length of Segment AB is equal to the length of segment AC. The length of segment BC is 4 less than twice the length of segment AB. If the perimeter of Triangle ABC is 52, find the length of segment AB.