23

I have a width: 240 I have aspect ratio: 2.40 I need to get the height based on those two variables. What's the formula?

Shawn
  • 233
  • 1
  • 2
  • 4

2 Answers2

70

Definition of the ratio:

ratio = width / height

Formula:

height = width / ratio = 240 / 2.40 = 100

Daniel Kvist
  • 3,032
  • 5
  • 26
  • 51
darma
  • 4,687
  • 1
  • 24
  • 25
10

example of calculating 2:40 . using javascript programming language.

var width = 240 ;
var rat1 = 2;
var rat2 = 40;

var ratio  = width / rat1;
var calculated_height = ratio * rat2;
Softmixt
  • 1,658
  • 20
  • 20