Any mathemeticians?

1. Senior Member
Join Date
Dec 1969
Posts
2,958

## Any mathemeticians?

We recently wrote a school grading app that used both weighted and non-weighted grades in their classes.<BR><BR>One of the teachers had 4 categories in a class, each weighted at 25%. Not that it changed the app but the question was, isn&#039;t that the same as a non-weighted class? Everyone agreed it was. However, when we put numbers to calculator we found that if you took the same grades and figured it as a weighted and a non-weighted class, using 25% for each category, the non-weighted can figure out to be up to 2% higher than the weighted.<BR><BR>Anyone care to take a stab at explainign this to poor dumb me?

2. Senior Member
Join Date
Dec 1969
Posts
96,118

## Show an example???

It might just be rounding errors? Or an error in your algorithm, even.<BR><BR>Mathematically, it *HAS* to be the same:<BR><BR>sum = 0.25 * grade1 + 0.25 * grade2 + 0.25 * grade3 + 0.25 * grade4 <BR><BR>*is* exactly the same as<BR><BR>sum = ( grade1 + grade2 + grade3 + grade4 ) / 4<BR><BR>since of course 1/4 is the same as 0.25.<BR><BR>I suspect cockpit error.<BR><BR><BR><BR>

3. Senior Member
Join Date
Dec 1969
Posts
96,118

## p.s. My degree is in Math...

...but that was mumblety-mumble years ago.<BR><BR>

4. Senior Member
Join Date
Dec 1969
Posts
16,931

## RE: p.s. My degree is in Math...

mumblety-mumble?<BR><BR>Gees, you are old ;-)<BR><BR>Craig.

5. Senior Member
Join Date
Dec 1969
Posts
2,958

## OK

here is one of the examples we tried.<BR><BR>Homework (25%) 92% &#124 87.5% &#124 83% &#124 100%<BR>Quiz (25%) 78% &#124 92.5%<BR>Test (25%) 63% &#124 93% &#124 87.5%<BR>Class (25%) 92% &#124 86%<BR><BR>OK if the class were not weighted the grade would be: 86.77%<BR><BR>If we used a wieghted formula the grade would be: 86.5%<BR><BR>The non-wieghted is the total of the grades/# of grades<BR><BR>The weighted is the total in each category/# of grades in that category. Add the resulting total and divide by 4 since that, in this case, is 25% for each category.<BR><BR>Now unless they told us incorrectly that is the way to figure a weighted grade.<BR><BR>And yes I knew you majored in math and hoped you would see this. While I don;t have a mathematics degree this doesn&#039;t make sense to me. It should, as you state, be exactly the same. I would love to prove the teacher&#039;s and the principal wrong so do tell.

6. Senior Member
Join Date
Dec 1969
Posts
96,118

## Actually...

...I didn&#039;t get my degree until age 27. (4 years in USAF in the middle there, then working full time while finishing off degree half time.)<BR><BR>So mumbledy-mumble doesn&#039;t reveal my real age, by 5 years.<BR><BR>

7. Senior Member
Join Date
Dec 1969
Posts
16,931

## So you're actually....

mumbledy-mumble + 5?<BR><BR>;-)<BR><BR>Craig.

8. Senior Member
Join Date
Dec 1969
Posts
2,958

## Sheesh

using your formula I come out with 86.51%<BR><BR>What the heck???<BR><BR>This should not be that tough for me. I&#039;m not an idiot despite proof to the contrary.

9. Senior Member
Join Date
Dec 1969
Posts
96,118

## Well, ready to feel silly?

Homework (25%) 92% &#124 87.5% &#124 83% &#124 100%<BR>Quiz (25%) 78% &#124 92.5%<BR>Test (25%) 63% &#124 93% &#124 87.5%<BR>Class (25%) 92% &#124 86%<BR><BR>Homework average: 90.625<BR>Quiz average: 85.25<BR>Test average: 81.16666666667<BR>Class average: 89.0<BR><BR>Sum of those: 346.04166666666667<BR><BR>Divided by 4: 86.5104166666667<BR><BR>***********<BR><BR>25% of Homework average: 22.65625<BR>25% of Quiz average: 21.3125<BR>25% of Test average: 20.2916666666667<BR>25% of Class average: 22.25<BR><BR>Sum of those: 86.5104166666667<BR><BR>Sure look identical to me.<BR><BR>I would have to assume that somewhere along the way you ROUNDED some of the numbers. Nope. Can&#039;t do that. If you use DOUBLE arithmetic in VBScript (accuracy of 14 or more decimal digits) you should get the same final rounded result, even if you round to 6 or 8 digits or more.<BR><BR>If you were doing this on a stupid desktop calculator that rounds every result to only 2 digits after the decimal point, then no wonder you got different results.<BR><BR><BR>

10. Senior Member
Join Date
Dec 1969
Posts
11,247

## RE: So you're actually....

Clng(mumbledy-mumble + 5)<BR><BR>Note: Not Cint!

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•