Sum() function



The Excel SUM function returns the sum of values supplied as multiple arguments. SUM can handle up to 255 individual arguments, which can include numbers, cell references, ranges, arrays, and constants.

Syntax

The syntax for the SUM function in Microsoft Excel is:

SUM( number1, [number2, ... number_n] )
OR
SUM ( cell1:cell2, [cell3:cell4], ... )

Parameters or Arguments

number

A numeric value that you wish to sum.

cell

The range of cells that you wish to sum.

Notes:

-          Sum function can also do the addition of decimal numbers and fractions.
-          If you are using SUM formula as =SUM( num1, num2, … num_n ) and in place of ‘num’ you have entered a non-numeric content then Sum function will throw an #Name? error.
-          But if you are using SUM Function as =SUM ( CellRange1, CellRange2, … CellRange_n ) and if any of the cell range contains a non-numeric content then Sum function will ignore this value.
-          Sum function is not a dynamic type of function. This means that if you have applied a Sum formula on a range of cells and then you filter out some values then the output of Sum function won’t change as it doesn’t change its result according the current values in the filter. It is better to use Subtotal function in such cases.

Example of SUM Formula:

In the above example I have applied four types of SUM functions and below I will explain them one by one.
1.       In the first example I have used a function =SUM(10,11,19). This Sum function simply adds-up all the values i.e. 10, 11 and 19 and hence the result is 40.
2.       In the second example I have used a function =SUM(10.2,9.6,2,4). Simple mathematics can tell us that 10.2+9.6+2.4 is 25.8 and hence the output is 25.8.
3.       In third example a fraction type Sum function is used =SUM(4/2,8/2). As 4/2 results into 2 and 8/2 results into 4 and addition of both these gives the resultant 6.
4.       In the fourth example Sum function is used with a non-numeric value =SUM(10,EXCEL) and this is the reason why it results into a #Name? error.
5.       In the above image I have used second type of SUM function [=SUM(B2:B10)] to which I have supplied a range of cells (B2:B10) as arguments. This sum function simply adds each element of the range and delivers the result as 60.

Shortcut for SUM Formula:

Instead for applying sum formula in the normal way, you can also apply the SUM Formula using a shortcut.
Simply select the range (containing your numbers to be added), then press “Alt +” key and the desired sum will be populated in the next cell.

Reference:


No comments:

Post a Comment

OR Function