In the example picture below, I know the points $A$, $B$, $C$ & $D$. How would I go about calculating $x$, $y$, $z$ & $w$ and $O$, but as points on the actual plane itself (e.g. treating $D$ as $(0, 0)$, $A$ as $(0, 1)$, $C$ as $(1, 0)$ and $B$ as $(1, 1)$.
Ultimately I need to be able to calculate any arbitrary point on the plane so I'm unsure as to whether this would be possible through linear interpolation of the results above or whether I would actually just have to do this via some form of Matrix calculation? I don't really know matrix math at all!
Just looking for something I can implement in JavaScript (in an enviroment that does support matricies).