title: Boundary enclosing a given set of points
body: <p>I am having a bit of a problem with an algorithm that I am currently using. I wanted it to make a boundary. </p>
  
  <p>Here is an example of the current behavior: </p>
  
  <p><a href="https://i.imgur.com/wrhH4wh.png" rel="noreferrer"><img src="https://i.imgur.com/wrhH4wh.png" alt="Current behavior"></a></p>
  
  <p>Here is an MSPaint example of wanted behavior:</p>
  
  <p><a href="https://i.stack.imgur.com/1DSmi.png" rel="noreferrer"><img src="https://i.stack.imgur.com/1DSmi.png" alt="Wanted behavior"></a></p>
  
  <p>Current code of Convex Hull in C#:<a href="https://hastebin.com/dudejesuja.cs" rel="noreferrer">https://hastebin.com/dudejesuja.cs</a></p>
  
  <p>So here are my questions:</p>
  
  <p>1) Is this even possible?</p>
  
  <p>R: Yes</p>
  
  <p>2) Is this even called Convex Hull? (I don't think so)</p>
  
  <p>R: Nope it is called boundary, link: <a href="https://www.mathworks.com/help/matlab/ref/boundary.html" rel="noreferrer">https://www.mathworks.com/help/matlab/ref/boundary.html</a></p>
  
  <p>3) Will this be less performance friendly than a conventional convex hull?</p>
  
  <p>R: Well as far as I researched it should be the same performance</p>
  
  <p>4) Example of this algorithm in pseudo code or something similar?</p>
  
  <p>R: Not answered yet or I didn't find a solution yet</p>