generating aperodic impulse train or triangular pulse or rectangular pulse

Hello all,

I want to generate aperodic signal of type impulse train or triangular pulse train or rectangular pulses train. i.e. time period b/w samples should vary for every 2 samples. I want to find frequency content from that signal by using FFT. I am new to matlab coding. Could anyone plz explain me how to generate the signal… Rest FFT and signal analysis i can do.

ANSWER

Matlabsolutions.com provide latest MatLab Homework Help,MatLab Assignment Help for students, engineers and researchers in Multiple Branches like ECE, EEE, CSE, Mechanical, Civil with 100% output.Matlab Code for B.E, B.Tech,M.E,M.Tech, Ph.D. Scholars with 100% privacy guaranteed. Get MATLAB projects with source code for your learning and research.

Attached is my triangle wave demo. Feel free to adapt it as needed.

% Creates triangle waves two ways, one using repmat() and 
% one using sawtooth() from the Signal Processing Toolbox.
format longg;
format compact;
clc; % Clear command window.
workspace; % Make sure the workspace panel is showing.
fontSize = 15;
close all; % Close figures from a prior run of this demo.
% If you have the signal Processing Toolbox, you can do
figure;
x=-30 : 0.01 : 30;
f=@(x) 10 * sawtooth(x ,0.5) + 5;
line(x,f(x),'color','r', 'linewidth',2.5)
grid on;
% Enlarge figure to full screen.
set(gcf, 'units','normalized','outerposition',[0 0 1 1]);
% Give a name to the title bar.
set(gcf,'name','Demo by ImageAnalyst','numbertitle','off')

SEE COMPLETE ANSWER CLICK THE LINK

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Technical Source

Technical Source

Simple! That is me, a simple person. I am passionate about knowledge and reading. That’s why I have decided to write and share a bit of my life and thoughts to.