0% found this document useful (0 votes)
8 views2 pages

DSP C22

The document outlines an experiment on Linear Convolution using Code Composer Studio. It includes the aim, software used, and the C code implemented for the experiment. The result confirms the successful verification of Linear Convolution.

Uploaded by

yimonor646
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views2 pages

DSP C22

The document outlines an experiment on Linear Convolution using Code Composer Studio. It includes the aim, software used, and the C code implemented for the experiment. The result confirms the successful verification of Linear Convolution.

Uploaded by

yimonor646
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

VNRVJIET 22071A04R2

Name of the Laboratory: Digital Signal Processing Experiment No: 2

Name of the Experiment: Linear Convolution Dat e:22-11-24

Linear Convolution
AIM: To verify Linear Convolution in Code composer studio.

SOFTWARE USED: Code Composer Studio

Code:

#include<stdio.h>

int main() {
int y[7];
int N = 4;
int i, j;

int x[8] = {1, 2, 3, 4, 0, 0, 0, 0};


int h[8] = {4, 3, 2, 1, 0, 0, 0, 0};

for (i = 0; i < 2 * N - 1; i++) {


y[i] = 0;
}
for (i = 0; i < 2 * N - 1; i++) {
for (j = 0; j <= i; j++) {
if (j < N && (i - j) < N) { // Check bounds
y[i] += x[j] * h[i - j];
}
}
}

for (i = 0; i < 2 * N - 1; i++) {


printf("%d ", y[i]);
}

return 0;
}
OUTPUT:

R2

RESULT: Hence, we have verified Linear Convolution in Code composer studio.

You might also like