I just need a basic idea as to how to approach these two problems.

1. A 1.020 g sample know to contain only magnesium carbonate, MgCO3, and calcium carbonate, CaCO3, was heated until the carbonated were decomposed to oxides as indicated by the following equations. After heating, the residue massed .536 g. What masses of MgCO3 and CaCO3 were present in the original sample?
CaCO3 -> CaO + CO2
MgCO3 -> MgO + CO2

2. A salt contains only barium and one of the halide ions. A .158 g sample of the salt was dissolved in water, and an excess of sulfuric acid was added to form barium sulfate, which was filtered, dried, and massed. Its mass was found to be .124 g. What is the formula of the barium halide?

1) Assume x moles of MgO and y moles of CaO.
Convert those moles to grams..
x*molmassMgO= mass of MgO
y*molmassCaO= mass of CaO

so
x*molmassMgO + y*molmassCaO= .536
But x and y are also the number of moles of the carbonates (see the balanced equation).
so x*molmassMgCO3 + y*molmassCaCO3=1.020
Two equations, solve for x, y.

I'm still a little confused as to how to solve this. If I have this:
x*molmassMgO [56.31] + y*molmassCaO [72.08]= .536
I still have two different variables in the equation. How do I solve for that?

You have two simultaneous equations. Solve them as you would for any two variables in two simultanaeous equations. The easy way is to use one equation to solve for x in terms of y. Then substitute that value for x in the other equation and solve for y. Post your work if you get stuck. We can help you better that way.

Here's my work, it's not adding up right.

56.31x + 72.08y = .536 g
72.08y = .536 g - 56.31 g
y= .00743sub6 - .781sub2 g

84.32x + 100.09(.00743sub6 - .781sub2) = 1.020 g
84.32x + .744sub2 - 78.1sub9x = 1.020 g
6.1sub3x +.744sub2 = 1.020 g
6.1sub3x = .2758 g
x= .044sub9 g

I haven't even finished it yet, but when I multiply x by the molar mass of MgCO3, the answer I got was 3.79, which is already over the combined mass of MgCO3 and CaCO3.
My question is, is my work wrong, or is that not the right way to get the masses?

Here's my work, it's not adding up right.
See my note below.
56.31x + 72.08y = .536 g
72.08y = .536 g - 56.31 g
y= .00743sub6 - .781sub2 g

84.32x + 100.09(.00743sub6 - .781sub2) = 1.020 g
84.32x + .744sub2 - 78.1sub9x = 1.020 g
6.1sub3x +.744sub2 = 1.020 g
6.1sub3x = .2758 g
x= .044sub9 g

I haven't even finished it yet, but when I multiply x by the molar mass of MgCO3, the answer I got was 3.79, which is already over the combined mass of MgCO3 and CaCO3.
My question is, is my work wrong, or is that not the right way to get the masses?

I think you are using the wrong molar masses. I have the molar mass MgO as 40.3 (all rounded to the nearest tenth).
CaO = 56.1
MgCO3 = 84.3
CaCO3 = 100.1
Let me know if you need me to check anything.

now i'm getting a negative x value =/
is there something wrong with my set-up? i fixed the molar mass of MgO, but i'm still using molar masses out to the hundreths place for my class.
my work now:
56.08x + 40.31y = .536 g
40.31y = .536 g - 56.08 g
y= .00132sub9 - 1.391sub2 g

84.32x + 100.09(.00132sub9 - 1.391sub2) = 1.020 g
84.32x + .133sub0 - 139.1sub2x = 1.020 g
-54.80x +.133sub0 = 1.020
6-54.80x = .877 g
x= -.0619

now i'm getting a negative x value =/
is there something wrong with my set-up? i fixed the molar mass of MgO, but i'm still using molar masses out to the hundreths place for my class.
my work now:
56.08x + 40.31y = .536 g
40.31y = .536 g - 56.08 g
y= .00132sub9 - 1.391sub2 g
You have reversed the meaning of X and Y for the two equations. It doesn't matter what we let x and y equal but we must be consistent. If we let
x=mols MgO
y=mols CaO
Then 40.3x + 56.1y = 0.536
84.3x + 100.1y = 1.020
I didn't look at your previous work again. I know the molar masses were not right. You may have reversed the equations there too. Anyway, check my work to make sure it is right, make any corrections you need to make for the significant figures (since I rounded here and there) and make your calculations again. You should end up with a little over 0.4 g MgCO3 and 0.6g+ for CaCO3 according to my quick run through. I will check from time to time to see if you run into any trouble.

84.32x + 100.09(.00132sub9 - 1.391sub2) = 1.020 g
84.32x + .133sub0 - 139.1sub2x = 1.020 g
-54.80x +.133sub0 = 1.020
6-54.80x = .877 g
x= -.0619

I made a typo. It should read "a little over 0.4 g MgCO3 and 0.6 g- (a little under 0.6 g) for CaCO3(unless I made an arithmetic error but I don't think I did.)

that fixed it =] I got .433 MgCO3 and .587 g CO3. thank you!

I made a typo. It should read "a little over 0.4 g MgCO3 and 0.6 g- (a little under 0.6 g) for CaCO3(unless I made an arithmetic error but I don't think I did.)

I worked the problem. 0.4333g give or take a little for MgCO3 and 0.5865g give or take a little for CaCO3. I wasn't careful about significant figures but 0.4333 + 0.5865 = 1.01989 which is close to 1.020 g for the total in the problem.

You have two simultaneous equations. Solve them as you would for any two variables in two simultanaeous equations. The easy way is to use one equation to solve for x in terms of y. Then substitute that value for x in the other equation and solve for y. Post your work if you get stuck. We can help you better that way.

also I have a question converning the second problem:
[2. A salt contains only barium and one of the halide ions. A .158 g sample of the salt was dissolved in water, and an excess of sulfuric acid was added to form barium sulfate, which was filtered, dried, and massed. Its mass was found to be .124 g. What is the formula of the barium halide?]
I know the equation is going to be something like
BaX2 + H2SO4 = BaSO4 + HX[probably]
My work so far is this:
[137.33 g Ba/ 233.39 g BaSO4] x .124 g = .0729sub6 g Ba

.158 g BaX- .0728sub6 g Ba = .0850sub4 g X
can i not make that assumption? and if that's correct, what do I do with the answer I just got to find the halide ion?

I think you can make that assumption but I wouldn't do it that way.
Keep the 0.124/233.39 = ?? mols BaSO4. That means ?? mols BaX2 in the formula since the equation is 1:1. Then we know grams/molar mass = mols; therefore, molar mass = grams/??mols = xx molar mass. Then subtract molar mass of Ba and divide the result by 2 to obtain the molar mass of 1 atom of X. Post your work if you get stuck. I whizzed thorough the work and I think the halide is Br. But check my work. Check my thinking.

"Then we know grams/molar mass = mols; therefore, molar mass = grams/??mols = xx molar mass."

That's the one part that's confusing me.
Doing the math for the first part out, I have .0005312 mol BaSO4, so I have .0005312 moles of BaX2.

What I'm confused on is molar mass [of what? BaSO4?] = grams [again, of what?]/ mols

I'm just a little confused about the labels.

BaX2 + H2SO4 ==> BaSO4 + 2HX

0.124 g BaSO4 x 1 mol BaSO4/233.39 g = 0.000531 mols BaSO4. That is also the # mols BaX2. So your are ok to here. You're almost home.
So we have 0.000531 mols BaX2.What I did before was "Remember grams/molar mass = # mols; rearranging we obtain molar mass* # mols = grams and rearranging again we obain molar mass = grams/# mols. So 0.158 g BaX2/0.000531 mols BaX2 = 297.4 = molar mass BaX2.
Since we know Ba has a molar mass of 137.3 then 297.4-137.3 = 160 and that divided by 2 is 80. Check my arithmetic. I had 79.9 the first time I did it. Anyway, that's close enough to tell you it is BaBr2. I hope this helps clear things up for you.

To solve the first problem, you need to set up two simultaneous equations and solve them for the variables x and y. Here are the steps:

1. Assume x moles of MgO and y moles of CaO.
2. Convert those moles to grams by multiplying by the molar masses: x * molar mass of MgO = mass of MgO and y * molar mass of CaO = mass of CaO.
3. Write the first equation using the masses: x * molar mass of MgO + y * molar mass of CaO = 0.536 g.
4. Write the second equation using the masses of the carbonates: x * molar mass of MgCO3 + y * molar mass of CaCO3 = 1.020 g.
5. Use the two equations to solve for x and y.

You've made some mistakes in your calculations. Make sure you're using the correct molar masses. For example, MgO has a molar mass of 40.3 g/mol, CaO has a molar mass of 56.1 g/mol, MgCO3 has a molar mass of 84.3 g/mol, and CaCO3 has a molar mass of 100.1 g/mol.

Go through your calculations again and verify your results. You should end up with approximately 0.433 g of MgCO3 and 0.587 g of CaCO3.