0

I have two regions like this

reg1 = ImplicitRegion[(-5. + x)^2 + (-3. + y)^2 <= 0.25 || (0.386909 + x Tan[25 \[Degree]] 
<= y <= 5.61309 - x Tan[25 \[Degree]] && 0 <= x <= 5.), {x, y}];

reg2 = ImplicitRegion[(-5. + x)^2 + (-3. + y)^2 <= 0.49 || (0.166233 + x Tan[25 \[Degree]]
<= y <= 5.83377 - x Tan[25 \[Degree]] && 0 <= x <= 5.), {x, y}];

Show[RegionPlot[reg1, AspectRatio -> Automatic], RegionPlot[reg2, AspectRatio -> Automatic]]

enter image description here

I need to see and work with their difference

RegionPlot[RegionDifference[reg2,reg1], AspectRatio -> Automatic]

but it brings about an error

RegionPlot::invplotreg: {RegionDifference[ImplicitRegion[Plus[<<2>>]^2+Plus[<<2>>]^2<=0.49||(0.166233 +Times[<<2>>]<=y<=5.83377 +Times[<<3>>]&&0<=x<=5.),{x,y}],ImplicitRegion[Plus[<<2>>]^2+Plus[<<2>>]^2<=0.25||(0.386909 +Times[<<2>>]<=y<=5.61309 +Times[<<3>>]&&0<=x<=5.),{x,y}]]} is not a valid region to plot. >>
J. M.'s missing motivation
  • 124,525
  • 11
  • 401
  • 574
T. Rihacek
  • 511
  • 2
  • 8

1 Answers1

1
RegionDifference @@ (DiscretizeRegion /@ {reg2, reg1})

enter image description here

ubpdqn
  • 60,617
  • 3
  • 59
  • 148