I am looking for a solution to get the largest possible rectangle inside a polygon.
currently I am using Arcpy for ArcGIS (python library), but there is no out of the box solution for getting it, instead there is a feature named Minimum Bounding Geometry (this returning the opposite result, a rectangle contains the polygon):
Example of the required result:
