Using Python scripting: How can I clip a polygon shapefile with parallel lines (polyline shapefile) to derive new inside polygon?
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It only takes a minute to sign up.Sign up to join this community
Here is how it can be done, but not the actual code to do it. The Feature to Polygon tool would create 3 polygons from the input you have shown in a new feature class. Then you could use a search cursor to process the original input lines layer to select each line separately and process each through a Select by Location operation, with the first using the create new selection option and the second using the select from current selection option. This would select the polygon where both lines touched it. Then you could use a search cursors on the new polygon feature class to read the geometry of the new polygon and an update cursor on the original polygon feature class that selects the original polygon and replaces its shape with the new shape.
Because you have no way of knowing if the removed portions of the polygon will be larger or smaller than the remaining polygon, and the centroid position representing the two irregularly shaped lines cannot be guaranteed to always fall inside of the polygon portion you want to keep, I don't think there is any other reliable process for getting the polygon portion you want to keep.