Sunteți pe pagina 1din 5

Fall 2019 Mechatronics and control engineering MCT-331L

Lab # 02
Mathematical Logical and Rational operators in Simulink
 Objective:
To explore logical and rational blocks using Simulink tool-box

 Introduction:
 Logical operators:
In digital electronics the logic gates are the certain type of
physical devices basically used to express the Boolean functions. The truth table is a tabular
representation of logical expression. Logic operators are AND, OR, NOT, NOR, XOR and
XNOR.

 Relational operators:
Relational operators are used to compare values, relational operators such as, ==, <,>, =< ,>=

 Procedure:
1) Firstly, we open MATLAB and open Simulink blank model.
2) Then we open its library, from which we opened math operations library and take some
blocks of math operations to perform different operations.

 Operations Performed:
 Absolute operator:

Fig 2.1(absolute operator)

Lab Instructor
Engr. Saqib Zafar University of engineering and technology, Lahore
Fall 2019 Mechatronics and control engineering MCT-331L

 Addition Operator:

Fig 2.2 (add operator)

 Product operator:

Fig 2.3(product operator)

 Reciprocal Operator:

Fig2.4(reciprocal operator)

 Unary Minus:

Fig 2.5(unary minus)

Lab Instructor
Engr. Saqib Zafar University of engineering and technology, Lahore
Fall 2019 Mechatronics and control engineering MCT-331L

 Magnitude-angle to complex operation:

Fig 2.6(Magnitude – angle to complex)

 Complex to magnitude-angle:

Fig 2.7(complex to magnitude- angle)

 Exponential operator:

Fig3.1(exponential function)
Lab Instructor
Engr. Saqib Zafar University of engineering and technology, Lahore
Fall 2019 Mechatronics and control engineering MCT-331L

 Relational operator:

Fig 4.1(relational operator)

Fig 4.2(relational operator)

 AND operation:

Fig 5.1(AND operator)

Lab Instructor
Engr. Saqib Zafar University of engineering and technology, Lahore
Fall 2019 Mechatronics and control engineering MCT-331L

 NAND Operator:

Fig 5.2(NAND operator)

 Lab Task:

Lab Instructor
Engr. Saqib Zafar University of engineering and technology, Lahore

S-ar putea să vă placă și