Can someone please help me with a excel work sheet formula for sum total of even number cells if the odd number cells value is 1 or 0.
Example:1 if a1=1,a3=1,a5=0,a7=1,a9=0,a11=1, then a2+a4+a8+a12
Example:2 if a1=1,a3=1,a5=0,a7=1,a9=0,a11=1, then a6+a10
Mike wrote:
Hi,Glad I could help for d23 etc use
25-Sep-08
Hi
Glad I could help for d23 etc use thi
=SUMPRODUCT(--(MOD(COLUMN(D23:KK23),2)=0),D23:KK23
Note all Ive done is change the range and altered the modulus to zero.
Columns D, F etc are even numbered so for D the formula days 2 mod 2 =
Mik
:
Previous Posts In This Thread:
Formula for sum of alternate cells
Folks
I'm trying to find a formula for summing the contents of alternate cells in
a row
I have a large workbook and want to calculate the contents of row 23 - i.e.
E23, G23, I23, K23, M23 etc etc, up to KK23. Is there a simple formula for
this
John Blackwell
RE: Formula for sum of alternate cells
John
=SUMPRODUCT(--(MOD(COLUMN(E23:KK23),2)=1),E23:KK23
Mik
:
Hi,Please array enter (Ctrl+Shift+Enter) the following
Hi
Please array enter (Ctrl+Shift+Enter) the following formul
SUM(IF((MOD(COLUMN(E23:I23),2)<>0),E23:I23)
What this formula does is that if the column number/2<>0, then it sums up
the numbers from those columns
--
Regards
Ashsih Mathu
Microsoft Excel MV
www.ashishmathur.co
Fantastic Mike - thank you.
Fantastic Mike - thank you
Sorry to be a pain, but how do I sum the other cells - i.e. D23, F23, H23
J23, L23 etc etc, up to KK23
Joh
:
Hi,Glad I could help for d23 etc use
Hi
Glad I could help for d23 etc use thi
=SUMPRODUCT(--(MOD(COLUMN(D23:KK23),2)=0),D23:KK23
Note all Ive done is change the range and altered the modulus to zero.
Columns D, F etc are even numbered so for D the formula days 2 mod 2 =
Mik
:
Mike, What is the significance of -- in formula.
Mike
What is the significance of -- in formula
Harshawardhan Shastr
:
Re: Formula for sum of alternate cells
For an explanation of the double unary minus, se
http://www.mcgimpsey.com/excel/formulae/doubleneg.htm
-
David Biddulp
"HARSHAWARDHAN. S .SHASTRI"
You could also try these
You could also try these two
=SUM(NPV({0,-2},D23:K23))/
=SUM(NPV({0,-2},,D23:K23))/
:
Clever. How do you find these Lori?
Clever. How do you find these Lori
-
Regards
Peo Sjoblom
Re: Formula for sum of alternate cells
Thanks Peo, i make them up
i figure there are many functions out there
which can be put to good use as long as you're aware of the limitations
NPV is a good example - other useful values for rate are
1/-0.5: for a binary su
9/-0.9 : for a decimal su
Big/small: for the first or last valu
eg: =NPV(1e20,A1:K1)*1e2
returns the first non-blank value in the row. Or...in Excel 2007 (cse)
=NPV(-0.9,,IFERROR(MID(A1,51-ROW(1:50),1)%,""))&"
extracts the numeric portion of a string such a
"apple 123 banana 345 pear 567 orange 678" -> 12334556767
:
Thanks for the info Lori, very interesting.
Thanks for the info Lori, very interesting
I love the last one and I know how to ge
numbers from a string as long as they are in one place.
--
Regards,
Peo Sjoblom
Submitted via EggHeadCafe - Software Developer Portal of Choice
Six Free Visual Studio 2010 MSDN Memberships Giveaway
http://www.eggheadcafe.com/tutorial...al-studio-2010-msdn-memberships-giveaway.aspx