Difference in shape, LxWxH, most similar proportions, regardless of scale

In summary, the equation for solving this type of problem is:(x0/x2-y0/y2)^2 + (x1/x2-y1/y2)^2 + (x2/x2-y2/y2)^2
  • #1
xinlo
3
0
this is not actually for homework, I am no longer in school, this is for a small application I am trying to write that compares dimensions. However, I believe this is the appropriate spot to post after reading the rules.

Homework Statement



okay, so let's say you got a shape, for example a rectangular prism.

192 x 210 x 212.

Then you have a list of other shapes and their dimensions

191,209,210
188,208,209
185,207,208
197,204,207
199,211,214

How would you pick the one that most closely matches the proportions of the original shape? scale does not matter, only proportions

Homework Equations



when its two dimensions its much simpler, you could just divide the length/width and pick the number closest to the result of the original.

The Attempt at a Solution



At first I had the idea of dividing the length/width and the length by the height seperately, figure the difference from the original shape, and then add those two differences together. The problem with this method is you can get large differences that are opposites, one positive and one negative that cancel each other out close to 0.

I don't need a solution to the above numbers, those numbers are just examples, I am just wanting to know what equation you would use to solve this type of problem.
 
Last edited:
Physics news on Phys.org
  • #2
Welcome to PF xinlo!

Thanks for actually reading the site rules! You have posted in the right place.

xinlo said:
this is not actually for homework, I am no longer in school, this is for a small application I am trying to write that compares dimensions. However, I believe this is the appropriate spot to post after reading the rules.

Homework Statement



okay, so let's say you got a shape, for example a rectangular prism.

192 x 210 x 212.

Then you have a list of other shapes and their dimensions

191,209,210
188,208,209
185,207,208
197,204,207
199,211,214

How would you pick the one that most closely matches the proportions of the original shape? scale does not matter, only proportions

Homework Equations



when its two dimensions its much simpler, you could just divide the length/width and pick the number closest to the result of the original.

The Attempt at a Solution



At first I had the idea of dividing the length/width and the length by the height seperately, figure the difference from the original shape, and then add those two differences together. The problem with this method is you can get large differences that are opposites, one positive and one negative that cancel each other out close to 0.

I don't need a solution to the above numbers, those numbers are just examples, I am just wanting to know what equation you would use to solve this type of problem.

Hmm...the first thought that comes to mind is: try using the RMS difference.
 
  • #3
Model rectangular prism LxWxH: 192 x 210 x 212

various rectangular prisms L,W,H
186,205,204
186,206,205
188,210,206
191,209,210
188,208,209
185,207,208
197,204,207
199,211,214
210,192,212 (should be farthest from a match)
384,420,424 (should be perfect match)

In the above data set I added one with the same dimensions but in a different order, also a couple where the width is greater than the height.
so my solving method should show those value as the least similar.
I also added one that has the exact same dimensions as the original only double, it should return the closest match.(perfect match)

below is how I did it, if I am reading wikipedia correctly: http://en.wikipedia.org/wiki/Root_mean_square

This is how I did it =SQRT(1/3(192^2+210^2+212^2))
(and then do the above for the other sets of dimensions and see which is closest.)

This RMS method would actually work perfectly it seems, if all data in the different sets is always L<W<H.

Also I realize when I originally asked the question, the data set I provided, this solution would have worked.
 
  • #4
You want to find the one that is closest to being geometrically similar. Here's an idea. First write the dimensions of all the prisms in ascending order. Then let the three numbers be the three components of a vector from the origin. Divide each of the choices by the magnitude of the vector to get a unit vector. Then take the dot products of all the unit vectors with the unit vector for the subject shape. The one giving the dot product closest to unity is the one closest to being geometrically similar.
 
  • #5
I ended up using the first suggestion, it ended up working perfectly, I just wasn't doing it correctly, given all objects have to remain facing the same direction (length cannot be swapped out for width.)

and then for y just plug in all other sets of numbers and the smallest value is the closest match.

=SQRT((x0/x2-y0/y2)^2 + (x1/x2-y1/y2)^2 + (x2/x2-y2/y2)^2)

x0,x1,x2 = 192,210,212 = 0
--------------------------------------------
y0,y1,y2 = 384,420,424 = 0
y0,y1,y2 = 191,209,210 = 0.006062527
y0,y1,y2 = 188,208,209 = 0.007700726
y0,y1,y2 = 186,206,205 = 0.014407578
y0,y1,y2 = 186,205,204 = 0.015581448
y0,y1,y2 = 185,207,208 = 0.016883492
y0,y1,y2 = 199,211,214 = 0.024675823
y0,y1,y2 = 188,210,206 = 0.029679298
y0,y1,y2 = 197,204,207 = 0.046307593
y0,y1,y2 = 210,192,212 = 0.120074736

Thank you both very much for the help :)
 
Last edited:

FAQ: Difference in shape, LxWxH, most similar proportions, regardless of scale

1. What is the difference in shape between objects?

The difference in shape refers to the variations in the physical appearance of objects. This can include differences in size, dimensions, curvature, and overall form.

2. How do you measure the length, width, and height of an object?

The length, width, and height of an object can be measured using various tools such as rulers, calipers, measuring tapes, or by using mathematical formulas. The units of measurement may vary depending on the scale of the object.

3. What does it mean when objects have similar proportions?

Similar proportions indicate that the objects have a similar ratio or relationship between their dimensions. This means that the objects have similar shapes, but may differ in size.

4. Can the concept of "similar proportions" be applied regardless of scale?

Yes, the concept of similar proportions can be applied regardless of scale. This means that the objects may have different sizes, but their dimensions are in the same ratio or relationship to each other.

5. How is the concept of "similar proportions" useful in scientific research?

The concept of similar proportions is useful in scientific research as it allows for comparisons and analysis of objects with varying sizes. This can be applied in fields such as biology, engineering, and physics to understand the relationship between objects and how they function.

Back
Top