Found 163 Articles for MATLAB

Convolution Shape (full/same/valid) in MATLAB

Manish Kumar Saini
Updated on 07-Aug-2023 16:04:03

173 Views

In digital signal processing and image processing, the convolution is a crucial mathematical operation. The primary function of the convolution is to combine two signals to produce a resulting signal. The resulting signal specifies the interaction between the two signals that we combined. In MATLAB, we can perform the convolution of two signals by using a built−in function ‘conv()’. This MATLAB function performs the convolution by using a discrete approximation of the integration. For this, it uses discrete samples of the input signals. Syntax The following is the general syntax for the ‘conv()’ function, a = conv(x, y, shape); ... Read More

Configure the Run Button for Functions in MATLAB

Manish Kumar Saini
Updated on 07-Aug-2023 15:40:57

46 Views

In this article, we will learn to configure the Run button for functions in MATLAB. In MATLAB, the `Run` button is used execute a MATLAB code. Also, MATLAB allows us to configure the `Run` button to execute a specific user defined function. Algorithm to Configure Run Button The step−by−step process to configure the Run button to execute a specific function in MATLAB is explained below: Step 1 − Firstly, create a new script to open the MATLAB editor. Step 2 − Define or create a function for which you want to configure the Run button. For example, we create ... Read More

Comparing Two Cell Arrays of Strings of Different Sizes in MATLAB

Manish Kumar Saini
Updated on 07-Aug-2023 15:27:49

160 Views

In this article, we will learn how to compare two cell arrays of strings of different sizes in MATLAB. Cell Array of Strings In MATLAB, a cell array of strings is a data structure that can store different types of elements. The element of a cell array are enclosed within curly braces `{}`. Syntax We can use the following syntax to create a cell array of strings, A = {'string1', 'string2', 'string3', …'stringN'}; Here, `A` is a cell array of strings that contains N string elements namely, `string1`, `string2`, …, `stringN`. In MATLAB, the cell arrays of strings are ... Read More

Boundary Extraction of Image using MATLAB

Manish Kumar Saini
Updated on 07-Aug-2023 15:25:52

511 Views

In an image, a boundary is an element that separates an object from the background of the image or two different regions within an image. Boundary provides information about the shape and structure of objects present in the image. Boundaries are mainly classified into the following two types: Inner Boundary It is the boundary of an object within an image that separates it from the image background. The inner boundary is basically the outline of the object and provides information about the shape of the object. Therefore, by extracting the inner boundary of an object, we can identify and analyze ... Read More

Black and White Optical Illusion in MATLAB

Manish Kumar Saini
Updated on 07-Aug-2023 15:23:01

52 Views

An optical or visual phenomenon that creates the perception of distortion, movement or any other type of fascinating visual effect by using back and white patterns is referred to as back and white optical illusion. These back and white patterns utilize the way our eyes and brain process the visual information and create an illusion to mislead our perception. The back and white optical illusions use various black and white patterns, shapes, and lines arranged in a specific style. These arrangements are made such that they can create illusion of movement, distortion, depth, and more. In this article, we will ... Read More

How to Remove NaN Values from a Matrix using MATLAB

Manish Kumar Saini
Updated on 26-Jul-2023 18:17:56

4K+ Views

In MATLAB, for removing NaN value from a matrix, the following two functions are most widely used. remmissing () isnan () Now let us understand the removal of NaN value from a matrix in MATLAB using these two functions with the help of example programs. Removing NaN Values Using the isnan () Function In MATLAB, we can use the "isnan()" function to find the NaN values in a matrix and then can be used to remove them using logical indexing. The "isnan ()" function returns a value TRUE (logic 1) for NaN elements and FALSE (logic 0) for ... Read More

Find the Exact String in a Cell Array in MATLAB

Manish Kumar Saini
Updated on 26-Jul-2023 18:12:17

279 Views

MATLAB is a programming environment developed for scientists and engineers to design and analyze system, perform data analysis, create visualizations, and more. MATLAB stands for Matrix Laboratory, it is a programming and interactive platform developed by MathWorks to provide a variety of tools for programming mathematical functions and operations, data analysis, etc. MATLAB is extensively used in different field of science, engineering, finance, economics, and more. Read this article to understand the process of finding the exact string in a cell array in MATLAB. What is a Cell Array in MATLAB? In MATLAB, a cell array is a data structure ... Read More

Find the Closest Value in an Array in MATLAB

Manish Kumar Saini
Updated on 26-Jul-2023 18:05:23

1K+ Views

MATLAB is a programming environment developed for scientists and engineers to design and analyze system, perform data analysis, create visualizations, and more. MATLAB stands for Matrix Laboratory, it is a programming and interactive platform developed by MathWorks to provide a variety of tools for programming mathematical functions and operations, data analysis, etc. MATLAB is extensively used in different field of science, engineering, finance, economics, and more. Read this tutorial to learn the different methods of finding the closest value in an array in MATLAB. But before that let's get an idea about Array in MATLAB. What is an Array in ... Read More

App Building Components in MATLAB

Manish Kumar Saini
Updated on 26-Jul-2023 17:06:40

90 Views

MATLAB is the acronym for Matrix Laboratory. MATLAB is a programming environment developed for scientists and engineers to design and analyze systems. MATLAB platform uses its MATLAB programming language which is a matrix-based language. MATLAB language allows users to write expression of computational mathematics in natural way. With the help of MATLAB, a user can analyze data, develop algorithms, design system models and applications, and more. Therefore, MATLAB is one of the most popular design and analysis tools used by engineers and scientists globally. It finds applications in several different fields of science and technology, including deep learning, machine learning, ... Read More

Write Data to Text Files in MATLAB

Manish Kumar Saini
Updated on 18-Jul-2023 13:17:33

259 Views

In MATLAB, there is a built-in function “fprintf()” that is used to write data to a text file. The best part of this function is that it writes formatted data to a text file exactly in the same way as specified. Syntax fprintf(fileID, FormateSpecifier, Variables); Format Specifiers in MATLAB The following table gives a list of different format specifiers used with the “fprintf()” function in MATLAB: S. No. Format Specifier Description 1. %d or ... Read More

Advertisements