### Imtiaz_rafi's blog

By Imtiaz_rafi, 3 years ago,

UPDT : FOUND THE SOLUTION.THANKS.

If I have only Four coordinate of a parallelogram then how should I find the straight height of that for calculating the area?

• +1

| Write comment?
 » 3 years ago, # |   +8 Is is always the case that $A_y = B_y$ and $C_y = D_y$? Because in that case it's just $D_y-A_y$ isn't it.
•  » » 3 years ago, # ^ |   +5 No. the coordinates can be in different line but ( Ay-By)==( Cy-Dy) are same
 » 3 years ago, # | ← Rev. 2 →   +9 I think it should be this $h=\left\lvert \frac{D_x(\frac{B_y-A_y}{B_x-A_x})-D_y-(\frac{A_xB_y-B_xA_y}{B_x-A_x})}{\sqrt{1+(\frac{B_y-A_y}{B_x-A_x})^2}}\right\rvert$ This is the general equation independent of what are the constraints on the points(The only thing I have assumed is that the given quadrilateral is a parallelogram). You can make further simplifications in this expression according to the problem.
•  » » 3 years ago, # ^ |   0 can you provide the source of that equation? thanks in advance <3
•  » » » 3 years ago, # ^ |   +3 I used some basic coordinate geometry to derive the above equation, you can learn it from the following links 1.Formula to find the equation of a line passing from 2 points: Resource 1 2. Formula to find the perpendicular distance of a point from a line : Resource 2 The basic logic I used was like, I first found the equation of the line AB using the formula given in resource 1 and then I found the perpendicular distance between the line AB and the point D using the formula given in resource 2
 » 3 years ago, # | ← Rev. 3 →   +11 Use shoelace theorem. Via shoelace the area is $\frac{|(a_x*b_y+b_x*c_y+c_x*d_y+d_x*a_y)-(a_y*b_x+b_y*c_x+c_y*d_x+d_y*a_x)|}{2}$. The base is just $\sqrt{(a_x-b_x)^2 + (a_y-b_y)^2}$ via pythagorean. Then just do the area/base for the height.
•  » » 3 years ago, # ^ |   0 Read the topic, he clearly mentions that we have to calculate the height without calculating area.
•  » » » 3 years ago, # ^ |   +4 My bad but the op is interested in the height so that he can calculate the area, and this one finds the area without the height, so I think it's fine.
•  » » 3 years ago, # ^ |   +3 just figured out that the area and height can be calculated in that way also. Thanks a lot bro.. This really works
 » 3 years ago, # | ← Rev. 2 →   +6 Let's say the sides are $\vec{AB}$ and $\vec{AD}$, then the height will be $AD*sin(\theta)$ where $\theta$ is the angle between $\vec{AB}$ and $\vec{AD}$. (We can calculate side vectors from the coordinates)
•  » » 3 years ago, # ^ | ← Rev. 2 →   0 UPDT: Got the idea now
•  » » » 3 years ago, # ^ |   0 The area of the parallelogram is the magnitude of the cross product of $\overrightarrow{AB}$ and $\overrightarrow{AD} = AB\cdot AD\cdot sin(\theta)$ so you would directly get the area if that's what you want, but you could then just divide by the base to get the height. The cross product's magnitude is represented in terms of the angle between the two vectors even though it can be calculated with just the coordinates.
•  » » » 3 years ago, # ^ |   0
•  » » » 3 years ago, # ^ | ← Rev. 2 →   0 The angle can be calculated by dot product. $\vec{a}.\vec{b} = abcos(\theta)$ $\implies cos(\theta) = \frac{\vec{a}.\vec{b}}{ab}$
 » 3 years ago, # |   +3 You can get two vectors $\overrightarrow{AD} =$ and $\overrightarrow{AB} =$. The scalar cross product $\overrightarrow {AD} \times \overrightarrow {AB}$ is the area of the parallelogram: $\mathbf{abs( \left(D_x-A_x\right)\left(B_y-A_y\right)-\left(D_y-A_y\right)\left(B_x-A_x\right) )}$