Skip to main content

Posts

Showing posts from July, 2018

APTITUDE NUMBER SYSTEM TRICKS

MATLAB TUTORIALS-3

TO PLOT DIFFERENT TYPES OF THE FINITE SEQUENCE SIGNAL IN MATLAB: TYPES OF SEQUENCES We use several elementary sequences in digital signal processing for analysis purposes. Their definitions and MATLAB representations follow. 1. Unit sample sequence: In MATLAB the function zeros(1,N) generates a row vector of N zeros, which can be used to implement δ(n) over a finite interval. However, the logical relation n==0 is an elegant way of implementing δ(n). For example, to implement over the n1 ≤n0 ≤n2 interval, we will use the following MATLAB function used the following code to generate the delta function in the MATLAB. function [x,n] = impseq(n0,n1,n2) % Generates x(n) = delta(n-n0); n1 <= n <= n2 % ---------------------------------------------- % [x,n] = impseq(n0,n1,n2) % n = [n1:n2]; x = [(n-n0) == 0]; stem(n,x); 2. Unit step sequence: In MATLAB the function ones(1,N) generates a row vector of N ones. It can be used to generate u(n) over a finite interva

Study of sampling theorem, effect of undersampling.

 Study of the sampling theorem, the effect of undersampling.   THEORY :-                                The real-life signals that we encounter in our day to day basis       are mostly analog signals. These signals are defined continuously in time and have an infinite range of amplitude values. In order to process these signals to obtain meaningful information, they need to be converted to a format which is easily handled by computing resources like microprocessors, computers etc... The first step in this process is to convert the real-time signal into discrete-time signals. Discrete-time signals are defined only at a particular set of time instances. They can thus be represented as the sequence of numbers with a continuous range of values.  The process of converting an analog signal (denoted as x(t)) to a digital signal (denoted as x(n)) is called the analog-to-digital conversion (referred to as digitization), usually performed by an analog-to-digital converter (ADC). Here t

MATLAB TUTORIAL-2

                  Effects of the the echos in MATLAB  HELLO FRIEND'S,  here i have posted the code which paste in the matlab and enjoy the echo effect in music processing,do it yourself and understand what is really effect of the echos. Echo Generation The most basic of all audio effects is that of time delay, or echoes. It is used as the building block of more complicated effects such as reverb or flanging. In a listening space such as a room, sound waves arriving at our ears consist of direct sound from the source as well as reflected off the walls, arriving with different amounts of attenuation and delays. Echoes are delayed signals, and as such are generated using delay units. For example, the combination of the direct sound represented by discrete signal y[n] and a single echo appearing D samples later (which is related to delay in seconds) can be generated by the equation of the form (called a difference equation)                                                    

MATLAB TUTORIALS-1

                         A Sinusoidal Wave Implementation                                      And Analyzer In this section, we will quickly start analyzing signals in time and frequency domains. Of course, knowing and applying math in the simulation environment are the key point of understanding. Therefore, this material represents only one side of the equation.   The theoretical spectrum, 𝑋(𝑓) of 𝑥(𝑡) = 𝐴𝑐𝑜𝑠(2𝜋𝑓𝑐 𝑡) is                                              𝑋(𝑓) = 𝐴^2 𝛿(𝑓 − 𝑓𝑐 ) + 𝐴^2 𝛿(𝑓 + 𝑓𝑐 )  and its power spectral density (PSD), 𝑆𝑥 (𝑓),                                                is 𝑆𝑥 (𝑓) = 𝐴^2/4 𝛿(𝑓 − 𝑓𝑐 ) + 𝐴^2/4 𝛿(𝑓 + 𝑓𝑐 ) The example presented here with A=1, fc=100Hz. Therefore, the peak value of the spectrum is ½ or -3Db.  The average power is A2 /2=0.5  The peak of the power spectrum is A2 /4=1/4 and is expressed in dBW as 10log(1/4) = −6dBW.  The Simulink Model is expressed in the reference