dbTalk Databases Forums  

Working out Square Footage with Feet and Inches

mailing.database.myodbc mailing.database.myodbc


Discuss Working out Square Footage with Feet and Inches in the mailing.database.myodbc forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Shaun
 
Posts: n/a

Default Working out Square Footage with Feet and Inches - 04-20-2006 , 09:43 AM






Hi,

I have measurements of rooms stored in a table for each house in feet and
inches, does anyone know how can I work out the square footage?

Thanks for your advice



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw


Reply With Quote
  #2  
Old   
Jay Blanchard
 
Posts: n/a

Default RE: Working out Square Footage with Feet and Inches - 04-20-2006 , 09:46 AM






[snip]
I have measurements of rooms stored in a table for each house in feet
and=20
inches, does anyone know how can I work out the square footage?
[/snip]

Convert to inches, multiply length * width, divide by 144 (one square
foot)

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=3...ie.nctu.edu.tw


Reply With Quote
  #3  
Old   
David T. Ashley
 
Posts: n/a

Default RE: Working out Square Footage with Feet and Inches - 04-20-2006 , 10:05 AM



There is a technique called "unit cancellation" that may serve you well.

The technique is essentially to treat each unit as an orthogonal vector
(orthogonal to all other units), so one unit can't be mixed with any other
unit.

The only way to convert is to multiply by various forms of "1". "1" is a
fraction like (2.54 cm)/(inch) or (1 inch)/(2.54 cm), where the same thing
is in the numerator and denominator.

You can cancel (i.e. cross out) the same units appearing in the numerator
and denominator.

The rules free you from having to remember conversion factors. You can just
multiply by various forms of "1".

For example, if one has 1000 square inches and wishes to know how many
square feet:

(1000 inch * inch) (1 foot / 12 inch) (1 foot / 12 inch) = 6.944 foot *
foot.

Notice that the "inch" x 2 in the numerator cancel with those in the
denominator. Because you have to "cancel" units (by crossing them out on
paper), it would be impossible to use "12" alone as the converstion factor,
as the units would come out to (foot * inch) rather than (foot * foot) if
you did this.

It is a system that helps to keep your head straight and prevent human
mistakes.

I hope there is a web page somewhere that describes this with illustrations.
It is hard to do in a text e-mail.

You can go surprisingly far with this technique if you forget conversion
factors and need to get them again. For example, suppose I've forgotten how
many kilometers per mile, but I do remember that there are 2.54 cm/inch ...

(1 mile)(5,280 foot/mile)(12 in/1 foot)(2.54cm/1 inch)(1m/100cm)(km/1000m) =
1.6093 km.

Dave.

Quote:
-----Original Message-----
From: Jay Blanchard [mailto:jblanchard (AT) pocket (DOT) com]
Sent: Thursday, April 20, 2006 10:46 AM
To: Shaun; mysql (AT) lists (DOT) mysql.com
Subject: RE: Working out Square Footage with Feet and Inches


[snip]
I have measurements of rooms stored in a table for each house in feet
and
inches, does anyone know how can I work out the square footage?
[/snip]

Convert to inches, multiply length * width, divide by 144 (one square
foot)

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=d...e3ft (DOT) com





--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw



Reply With Quote
  #4  
Old   
Tim Lucia
 
Posts: n/a

Default RE: Working out Square Footage with Feet and Inches - 04-20-2006 , 11:20 AM



I read this as a SQL syntax question, not a math word problem. As in

SELECT ..., (some expression equaling sq ft) AS sqft...

-----Original Message-----
From: David T. Ashley [mailto:dta (AT) e3ft (DOT) com]
Sent: Thursday, April 20, 2006 11:15 AM
To: Jay Blanchard; Shaun; mysql (AT) lists (DOT) mysql.com
Subject: RE: Working out Square Footage with Feet and Inches

There is a technique called "unit cancellation" that may serve you well.

The technique is essentially to treat each unit as an orthogonal vector
(orthogonal to all other units), so one unit can't be mixed with any other
unit.

The only way to convert is to multiply by various forms of "1". "1" is a
fraction like (2.54 cm)/(inch) or (1 inch)/(2.54 cm), where the same thing
is in the numerator and denominator.

You can cancel (i.e. cross out) the same units appearing in the numerator
and denominator.

The rules free you from having to remember conversion factors. You can just
multiply by various forms of "1".

For example, if one has 1000 square inches and wishes to know how many
square feet:

(1000 inch * inch) (1 foot / 12 inch) (1 foot / 12 inch) = 6.944 foot *
foot.

Notice that the "inch" x 2 in the numerator cancel with those in the
denominator. Because you have to "cancel" units (by crossing them out on
paper), it would be impossible to use "12" alone as the converstion factor,
as the units would come out to (foot * inch) rather than (foot * foot) if
you did this.

It is a system that helps to keep your head straight and prevent human
mistakes.

I hope there is a web page somewhere that describes this with illustrations.
It is hard to do in a text e-mail.

You can go surprisingly far with this technique if you forget conversion
factors and need to get them again. For example, suppose I've forgotten how
many kilometers per mile, but I do remember that there are 2.54 cm/inch ...

(1 mile)(5,280 foot/mile)(12 in/1 foot)(2.54cm/1 inch)(1m/100cm)(km/1000m) =
1.6093 km.

Dave.

Quote:
-----Original Message-----
From: Jay Blanchard [mailto:jblanchard (AT) pocket (DOT) com]
Sent: Thursday, April 20, 2006 10:46 AM
To: Shaun; mysql (AT) lists (DOT) mysql.com
Subject: RE: Working out Square Footage with Feet and Inches


[snip]
I have measurements of rooms stored in a table for each house in feet
and inches, does anyone know how can I work out the square footage?
[/snip]

Convert to inches, multiply length * width, divide by 144 (one square
foot)

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=d...e3ft (DOT) com





--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=t...ahoo (DOT) com



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw



Reply With Quote
  #5  
Old   
Jay Blanchard
 
Posts: n/a

Default RE: Working out Square Footage with Feet and Inches - 04-20-2006 , 11:33 AM



[snip]
I read this as a SQL syntax question, not a math word problem. As in

SELECT ..., (some expression equaling sq ft) AS sqft...
[/snip]

Cool, then do it!

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=3...ie.nctu.edu.tw


Reply With Quote
  #6  
Old   
RedRed!com IT Department
 
Posts: n/a

Default Re: Working out Square Footage with Feet and Inches - 04-20-2006 , 11:40 AM



Jay Blanchard wrote:
Quote:
[snip]
I read this as a SQL syntax question, not a math word problem. As in

SELECT ..., (some expression equaling sq ft) AS sqft...
[/snip]

Cool, then do it!


It would all depend on how he has his feet and inches saved in the
table, and of course, the field names. If we can get that info then
maybe we would be better able to post a solution.

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw



Reply With Quote
  #7  
Old   
Nicolas Verhaeghe
 
Posts: n/a

Default RE: Working out Square Footage with Feet and Inches - 04-21-2006 , 12:36 AM




""RedRed!com IT Department"" <itdept (AT) redred (DOT) com> wrote in message=20
news:4447B97F.5020105 (AT) redred (DOT) com...
Quote:
Jay Blanchard wrote:
[snip]
I read this as a SQL syntax question, not a math word problem. As in

SELECT ..., (some expression equaling sq ft) AS sqft... [/snip]

Cool, then do it!



It would all depend on how he has his feet and inches saved in the=20
table,
and of course, the field names. If we can get that info then maybe we=20
would be better able to post a solution.
Sorry Guys, I am just storing the X and Y, so 6 foot 11 inches would be=20
stored as 6.11=20

----------------

I hope the data type is a varchar or something like that.

So if I am right the "decimal" (actually it's pseudo-duodecimal) part is
stored as "00" to "11"?

I would use string functions to separate the pseudo-duodecimal parts, =
devide
it by 12 to make it a decimal, add to the feet parts, then use these =
values
to get a square footage in decimals.=20

Table dimensions:

ID X Y
1 6.11 5.04
2 6.02 6.00

select ID,
cast((right(x, 2) / 12 + left(x,length(x)-3)) as decimal) as decimalX,
cast((right(y, 2) / 12 + left(y,length(y)-3)) as decimal) as decimalY,
cast((right(x, 2) / 12 + left(x,length(x)-3)) as decimal) * =
cast((right(y,
2) / 12 + left(y,length(y)-3)) as decimal) as decimalSQFT
from dimensions

Gives:

ID decimalX decimalY decimalSQFT
1 6.92 5.33 36.8836
2 6.17 6 37.02

Now if you want to convert the decimal part into square inches, you're =
on
your own!





--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=3...ie.nctu.edu.tw



Reply With Quote
  #8  
Old   
Shaun
 
Posts: n/a

Default Re: Working out Square Footage with Feet and Inches - 04-21-2006 , 03:49 AM




""Nicolas Verhaeghe"" <nicolas (AT) whiteecho (DOT) com> wrote


""RedRed!com IT Department"" <itdept (AT) redred (DOT) com> wrote

Quote:
Jay Blanchard wrote:
[snip]
I read this as a SQL syntax question, not a math word problem. As in

SELECT ..., (some expression equaling sq ft) AS sqft... [/snip]

Cool, then do it!



It would all depend on how he has his feet and inches saved in the
table,
and of course, the field names. If we can get that info then maybe we
would be better able to post a solution.
Sorry Guys, I am just storing the X and Y, so 6 foot 11 inches would be
stored as 6.11

----------------

I hope the data type is a varchar or something like that.

So if I am right the "decimal" (actually it's pseudo-duodecimal) part is
stored as "00" to "11"?

I would use string functions to separate the pseudo-duodecimal parts, devide
it by 12 to make it a decimal, add to the feet parts, then use these values
to get a square footage in decimals.

Table dimensions:

ID X Y
1 6.11 5.04
2 6.02 6.00

select ID,
cast((right(x, 2) / 12 + left(x,length(x)-3)) as decimal) as decimalX,
cast((right(y, 2) / 12 + left(y,length(y)-3)) as decimal) as decimalY,
cast((right(x, 2) / 12 + left(x,length(x)-3)) as decimal) * cast((right(y,
2) / 12 + left(y,length(y)-3)) as decimal) as decimalSQFT
from dimensions

Gives:

ID decimalX decimalY decimalSQFT
1 6.92 5.33 36.8836
2 6.17 6 37.02

Now if you want to convert the decimal part into square inches, you're on
your own!


Thanks for your reply,

I have stored the dimensions as decimal(4,2), does this make a difference?



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw



Reply With Quote
  #9  
Old   
2wsxdr5
 
Posts: n/a

Default Re: Working out Square Footage with Feet and Inches - 04-21-2006 , 09:21 AM



Shaun wrote:

Quote:
I have stored the dimensions as decimal(4,2), does this make a difference?


not a very good way to do it if you ask me but here is how to do the
calculation.

SELECT ((FLOOR(X) + ((X - FLOOR(X))/0.12)) * (FLOOR(Y) + ((Y -
FLOOR(Y))/0.12))) as SqFt.

FLOOR(X) gives you 6 from the 6.11
X - FLOOR(X) gives you the .11 part
..11/.12 gives you the appropriate fraction of a foot.to add back to X
then the same thing for Y and multiply.

--
Chris W
KE5GIX

Gift Giving Made Easy
Get the gifts you want &
give the gifts they want
One stop wish list for any gift,
from anywhere, for any occasion!
http://thewishzone.com


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql?unsub=m...ie.nctu.edu.tw



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.