Attaching constraints to different frame within a main frame


How can we attach two different frames with a constraint so that if we resize it maintains the proportion.
Please refer the attached image.