Ibuprofen, the active ingredient in advil, is made up of carbon, hydrogen, and oxygen atoms. When a sample of ibuprofen, weighing 5.000 g, burns in oxygen, 13.86 g of CO2 and 3.926 g of water are obtained. What is the simplest formula of ibuprofen?

My work:
13.86 g CO2/ 12.01 g C= 1.15 g C
3.926 g H2O/ 2.02 = 1.94 g H
13.86 g CO2 + 3.926 g H2O = 17.48sub6 g products
17.48sub6 g - 3.09 = 14.40 g O
1.15 g C x 1mol/12.01 g= .0957sub5 mol C
1.94 g H x 1mol/1.01 g= 1.92sub0 mol H
14.40 g O x 1mol/16.00= .9000 mol O
divide all by .0957sub5...
the formula comes out to C10H201O94
My problem is, the 14.40 g O isn't just the oxygen in the ibuprofen, but the oxygen in the combustion as well. how do I find out just what's in the ibuprofen so I get the correct formula?

Your work is wrong.

To get the grams of C in CO2, find the fraction of C in CO2, which is 12/(12+2*16)= 12/40
Then, grams C= 13.86 * 12/40 g C
then moles C= gramsC/12

Do the same with H.
Then, to find O, add the grams H and grams C, subtract them from 5.000. Then figure the grams O, and moles O.

Now, having moles of all, do this.
moles C xxxx
moles H yyyy
moles O zzzz

take the smallest of the three numbers, and divide it into all the numbers to get a whole number ratio.

example
moles C 4.53
moles H 9.05
moles O 12.22

divide all by 4.53
moles C 1
moles H 2
moles O 3
CH2O3 in this example. Here is another more complicated:
moles C 4.53
moles H 11.35
moles O 12.22
divide,
moles C 1
moles H 2.5
moles O 3
Now here, to get a whole number ratio , double the numbers..
moles C 2
moles H 5
moles O 6
C2H5O6

Thank you, I assumed something was wrong when I didn't end up using the 5.000 g in my calculation.
I've used this set-up before, and for this problem after doing it this way, I received C101H70O20. This doesn't seem right to me. I think any error I have might have occurred around here:
moles C= .3149sub 2
moles H= .217sub 8
moles O= .0623sub 6
I divided everything by .0623sub 6 [smallest number] and got
moles C= 5.05
moles H= 3.5
moles O= 1
and multiplied everything by 20 to get a whole number ratio.
The molar masses I used for all my calculations:
12.01 g/mol = C
1.01 g/mol = H
16.00 g/mol = O
Did I make an error, or is this correct?

Thank you, I assumed something was wrong when I didn't end up using the 5.000 g in my calculation.
I've used this set-up before, and for this problem after doing it this way, I received C101H70O20. This doesn't seem right to me. I think any error I have might have occurred around here:
moles C= .3149sub 2 OK to here,
moles H= .217sub 8 There are 2 mols H in H2O. This will change mols H as well as grams H AND grams oxygen.
moles O= .0623sub 6
I divided everything by .0623sub 6 [smallest number] and got
moles C= 5.05
moles H= 3.5
moles O= 1
and multiplied everything by 20 to get a whole number ratio.
The molar masses I used for all my calculations:
12.01 g/mol = C
1.01 g/mol = H
16.00 g/mol = O
Did I make an error, or is this correct?
See comments at H line.

im getting that the moles C = .347

moles H = .436
moles O = 0.025

and getting a formula of C14H17O
However, i looked it up on wiki and saw that the formula for ibuprofen is in fact i C13H18O2.
the C/H discrepancy is understandable, but the O2 to O is not. Could i have missed something that leads to a doubling of the moles O?

Yes, you made an error in calculating the moles of hydrogen (H). You correctly determined that there are 3.926 g of water obtained, but you divided it by the molar mass of hydrogen (2.02 g/mol) instead of dividing it by the molar mass of water (18.02 g/mol).

To correct this, you need to divide 3.926 g H2O by 18.02 g/mol and then multiply it by 2 (since there are 2 moles of hydrogen in 1 mole of water). This will give you the correct moles of hydrogen.

So, moles H = (3.926 g H2O / 18.02 g/mol) * 2

Once you have the correct moles of carbon (C), hydrogen (H), and oxygen (O), you can divide them by the smallest value (moles O in this case) to get a whole number ratio. Then, multiply these ratios by an appropriate factor to obtain a whole number ratio.

So, after correcting the moles H value and dividing everything by moles O (0.06236), you would get the following ratios:

moles C = 5.054
moles H = 3.505
moles O = 1.000

To obtain a whole number ratio, you can multiply all the values by a factor of 2.

moles C = 10
moles H = 7
moles O = 2

Therefore, the simplest formula of ibuprofen is C10H7O2.