Showing posts with label Constants. Show all posts
Showing posts with label Constants. Show all posts

Terminology of Boolean Expressions

A Boolean expression has the following terms

Literals
A literal is a single Boolean variable or it's complement
Constant
A constant is a value or the quantity which has a fixed (unchanging) value. In real number (conventional) algebra, constants include all integers and fractions. In Boolean Algebra, there are only two possible constants 1 and 0. These two constants are used to describe true and false, YES or NO, etc.
Variable
A variable is a quantity which can change its value by taking on the value of any constant. At any one itme the variable has only one particular value of constant. There are only two values of constants in the Boolean System. Therefore, a variable in Boolean algebra can only be either 0 or 1. Variables are denoted by letters.
Term
A term is a literal or a collection of literals.
Product Term
A product ( logical AND) of several different literals is called the product term. For example :
A.B' is a product term
Sum Term
The Logical OR of Literals is called the sum term. For example:
A+B'+C
is an example of sum term
Sum of Products
It is the sum (logical OR) of product terms. For example 
A.B' +B.C + A.B.C
is the sum of three different erms i.e. A.B', B.C and A.B.C
Product of Sum
It is tthe product (logical AND) of sum terms. For example:
(A+B).(A+B'+C).(A+C)
is the product of three different sum terms i.e. (A+B), (A+B'+C) and (A+C)
Minterm
A minterm is an AND function that includes each variable once in its normal or complemented form. This is also known as the standard sum of products. For example:
If you have two variables, A and B, there are eight possible terms:
A, B, A', B', A'B', A'B, AB' and AB.
Similarly for three variables we have 26 possible terms.
Maxterm
A maxterm is a logical OR function that includes each variable once in its normal or complemented form. This is known as standard product of sums.

Constants, Data Type Conversion, Visual Basic Built-in Functions

Constants are named storage locations in memory, the value of which does not change during program Execution. They remain the same throughout the program execution. When the user wants to use a value that never changes, a constant can be declared and created. The Const statement is used to create a constant. Constants can be declared in local, form, module or global scope and can be public or private as for variables. Constants can be declared as illustrated below.

Public Const gravityconstant As Single = 9.81

Predefined Visual Basic Constants
The predefined constants can be used anywhere in the code in place of the actual numeric values. This makes the code easier to read and write.   LEARN MORE >>>>>