ENGINEERING PROJECT

Matlab/Simulink Program

4:48 PM

Function of Block: MUX

Posted by Shahrul




Figure below show the Mux block


  • Mux
Combine several input signals into a vector


  • Library
Signal Routing


  • Description
The Mux block combines its inputs into a single vector output. An input can be a scalar or vector signal. All inputs should be of the same data type and numeric type.

Note: The Mux block allows you to connect signals of differing data and numeric types and matrix signals to its inputs. In this case, the Mux block outputs a bus signal combining the inputs. In other words, the Mux block behaves like a Bus Creator block. Nevertheless, you should use Bus Creator blocks in such cases to ensure that your model will run in future releases of Simulink, which may not support the use of Mux blocks as Bus Creators. If your model currently uses Mux blocks as Bus Creators, you may want to consider replacing the Mux blocks with equivalent Bus Creator blocks (see Mux blocks used to create bus signals for more information).


The Mux block's Number of Inputs parameter allows you to specify input signal names and sizes as well as the number of inputs. You can use any of the following formats to specify this parameter:

  • Scalar
Specifies the number of inputs to the Mux block. When this format is used, the block accepts scalar or vector signals of any size. Simulink assigns each input the name signalN, where N is the input port number.

  • Vector
The length of the vector specifies the number of inputs. Each element specifies the size of the corresponding input. A positive value specifies that the corresponding port can accept only vectors of that size. For example, [2 3] specifies two input ports of sizes 2 and 3, respectively. If an input signal width does not match the expected width, Simulink displays an error message. A value of -1 specifies that the corresponding port can accept scalars or vectors of any size.

  • Cell array
The length of the cell array specifies the number of inputs. The value of each cell specifies the size of the corresponding input. A scalar value N specifies a vector of size N. A value of -1 means that the corresponding port can accept scalar or vector signals of any size.

  • Signal name list
You can enter a list of signal names separated by commas. Simulink assigns each name to the corresponding port and signal. For example, if you enter position,velocity, the Mux block will have two inputs, named position and velocity.

Note: Simulink hides the name of a Mux block when you copy it from the Simulink block library to a model



  • Data Type Support
The Mux block accepts real or complex signals of any data type supported by Simulink, including fixed-point data types.

For a discussion on the data types supported by Simulink, see Data Types Supported by Simulink in the Simulink documentation.


  • Number of inputs
The number and size of inputs. You can enter a comma-separated list of signal names for this parameter field.


  • Display option
The appearance of the block in the model.




Thank You..

0 comments:

Electric machines play an important role in industry as well as our day to day life. They are used to generate electrical power in power plants and provide mechanical work in industries. They are also an indispensable part of our daily lives. Electric machines are very important pieces of equipment in our everyday lives. The DC machine is considered to be basic electric machines.

The aim of this final year project is to introduce students to the modeling of power components and to use computer simulation as a tool for conducting transient and control studies. Simulation can be very helpful in gaining insights to the dynamic behavior and interactions that are often not readily apparent from reading theory. Simulation is often chosen by engineers to study transient and control performance or to test conceptual designs.

MATLAB/SIMULINK is used because of the short learning curve that most students require to start using it, its wide distribution, and its general purpose of nature. This will demonstrate the advantages of using MATLAB for analyzing power system steady-state behavior and its capabilities for simulating transients in power systems and power electronics, including control system dynamic behavior