3 Formulas, Ranges, Functions
3 Formulas, Ranges, Functions
3 Formulas, Ranges, Functions
Formulas
Formulas perform operations such as
addition, multiplication, and comparison on
worksheet values.
Formulas can refer to other cells on the same
worksheet, cells on other worksheets in the
same workbook, or even cells on worksheets
in other workbooks.
Formulas may make use of built-in functions.
Excel knows you are entering a formula in a
cell because every formula starts with an =
sign.
If you forget the = sign, what you enter will
be treated as text (unless it can be
interpreted as a number in some format).
The following example adds the value of
cell B4 to 25 and then divides the result by
the sum of cells D5, E5, and F5.
= (B4+25)/SUM(D5:F5)
This example illustrates the use of
– The cell reference B4
– The numerical constant 25
– Arithmetic operators + and /
– The use of parentheses to specify order of
calculation
– The built-in SUM function
– A range reference D5:F5
About formula syntax
Formulas calculate values in an order based
on usual mathematical conventions.
You can always add parentheses to control
the order of calculation.
For example, 4+3*2 is interpreted as
4+(3*2), which is 10.
If you want the addition done first, use
(4+3)*2, which is 14.
Calculation operators in formulas
Operators specify the type of calculation
that you want to perform on the elements of
a formula.
Microsoft Excel includes four different
types of calculation operators: arithmetic,
comparison, text, and reference.
Reference operators are used in range
references, and we examine them later.
Arithmetic operators perform basic
mathematical operations such as addition,
subtraction, or multiplication; combine
numbers; and produce numeric results.
Arithmetic operator Meaning and
Example
+ (plus sign) Addition 3+3
– (minus sign) Subtraction 3-1 or
Negation -1
* (asterisk) Multiplication 3*3
/ (forward slash) Division 3/3
% (percent sign) Percent 20%
^ (caret) Exponentiation 3^2
Comparison operators compare two values
and then produce the logical value TRUE or
FALSE.