title: Create a function that finds the points distanced r units by two lines
body: <p>I have <strong>two lines</strong> defined <strong>by two points</strong> each(P1, P2, P3, P4).</p>
  
  <p>I'd like to find the <strong>2 points</strong>(X0, Y0) that are <strong>distanced r units</strong> <strong>from both lines</strong>.</p>
  
  <p>I found a way but I think it's too long to solve(too difficult for me) and maybe there's one shorter(<a href="https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line" rel="nofollow noreferrer">https://en.wikipedia.org/wiki/Distance_from_a_point_to_a_line</a>).</p>
  
  <p>my way:
  <a href="https://i.stack.imgur.com/tLjeD.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tLjeD.png" alt="my solution"></a>
  Without solving it it's impossible tp create the function</p>
  
  <p>I'd like to have the solution not the sistem.</p>
  
  <p>Example(I'd like to find the <strong>yellow points</strong> knowing r):
  <a href="https://i.stack.imgur.com/U3GtD.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/U3GtD.png" alt="enter image description here"></a></p>
  
  <p>Thanks.</p>
  
  <p>(Sorry for my terrible english)</p>