How can I plot a point on an equilateral triangle base on 3 input values

176 Views Asked by At

I have an equilateral triangle I am trying to plot a point on the triangle with the following information:

  • $V_1, V_2, V_3$ are some integer between 0 and 5.

  • If $V_1 = 5,$ and $V_1, V_2 = 0,$ the plot point will be at the top point of the triangle

  • if $V_2 = 5,$ the others are $0,$ the plot point will be at the bottom left angle

  • if $V_3 = 5,$ and the others are $0,$ the plot point will be at the bottom right angle

now the tricky part ...

  • if the formula is right, when $V_1,V_2 >0$ and $V_3=0,$ the plot point will be somewhere on the left side of the triangle.

  • if $V_1= V_2$, the point would be in the center of that line.

And same with the other inputs:

  • When $V_1, V_3 > 0$ and $V_2 = 0$ the point will be on the right edge.

  • when $V_1 = 0$ and $V2, V_3 > 0$ it will be on the bottom edge.

I need some solution where

  • $x = f_1(v_1, v_2, v_3)$
  • $y = f_2(v_1, v_2, v_3)$

This is will ultimately be used for drawing with computer software where the origin is such that the top of the triangle $Y=0,$ the left $X=0,$ and the entire triangle exists where $X$ and $Y$ are positive. But of course I can translate that if I can find any equations to get the $X$ and $Y$ on any set of coordinates.