This is a covalent compound of carbon and hydrogen atoms. We assume a compound sample mass of 100 grams. We use the given mass percent values to find the mass of each element in the sample:
m
C
=
0.8171
×
100
g
=
81.71
g
m
H
=
0.1829
×
100
g
=
18.29
g
Using the known molar masses, the molar quantities of carbon and hydrogen in this sample are:
n
C
=
81.71
g
×
m
o
l
12.01
g
=
6.803
m
o
l
n
H
=
18.29
g
×
m
o
l
1.01
g
=
18.11
m
o
l
The molar ratio of the elements is:
C
6.803
H
18.11
If we divide both subscripts by the smallest value and multiply by 3, then the empirical formula will be:
C
3
H
8