Table of Contents

calculating the possible angles of rotation of a rectangular object inside a larger rectangle

see also:

Introduction

Basic calculation method

  • if the diagonal of the smaller rectangle is less than the shortest side of the larger rectangle, it can be fully rotated 90deg and only touch maximum of two sides
  • if the diagonal of the smaller rectangle is more than the diagonal of the larger rectangle then it cannot be rotated at all
  • if the diagonal of the smaller rectangle is equal to the shortest length of the larger rectangle then the angle where 3 corners touch is 90deg - angle of the diagonal of the smaller rectangle

Example