Analog vs Digital Communication System

Feature

Analog Communication

Digital Communication

Signal Type

Continuous-time (sine wave, etc.)

Discrete-time (binary 0s and 1s)

Noise Immunity

Low (prone to distortion)

High (noise can be detected/corrected)

Bandwidth Requirement

Usually, lower

Usually, higher

Transmission Quality

Degrades with distance

Maintains quality with regeneration

Security

Less secure

More secure (encryption possible)

Cost

Cheaper hardware

Costlier due to encoding/processing

Multiplexing

Frequency Division Multiplexing (FDM)

Time/Frequency/Code Division Multiplexing

Applications

Analog radio, landline telephony

Internet, mobile phones, satellite links

Signal Processing

Harder to analyze and process

Easier (digital circuits, software tools)




Searching Problem in AI

Q. A farmer has a wolf, a goat and a cabbage on the west side of a river. He wants to get all of his animals and cabbage across the river onto the east side. The farmer has a row boat but he only has enough room for himself and one other thing. The wolf will eat the goat if they are left together alone. The goat will eat the cabbage if they are left together alone. How can the farmer get everything on the east side? Draw the search tree and show the final solution.

Solution:

Farmer, Wolf, Goat, Cabbage = (f,w,g,c)

West side, East side = (W,E)

Initially, all are on the West side.

                                         (W, W, W, W)

Then,

Line Spectrum of Signal

Q. Plot the line spectrums of x(t) =12 + 6sin (140πt +30°) - 9cos(80πt-70°).

Solution:

Let’s Analyze and Plot the Line Spectrum of

x(t) = 12 + 6sin(140πt+300) − 9cos(80πt−700)

Step 1: Convert all terms to cosine form

Use the identity: sin(θ) = cos(θ−900)

So,

6sin(140πt+300) = 6cos(140πt−600)

−9cos(80πt−700) = 9cos(80πt+1100)

Thus, x(t) = 12 + 6cos(140πt−600) + 9cos(80πt+1100)

Step 2: Frequencies, Amplitudes, Phases

Term

Frequency (Hz)

Amplitude

Phase

12 (DC)

0

12

6cos(140πt−600)

f=70

6

-60°

9cos(80πt+1100)

f=40

9

+110°

 We split each cosine into two spectral lines at ±f with half the amplitude.

Stack Implementation using Array

// Static Implementation of Stack

#include<stdio.h>

#include<conio.h>

#define N 5

int stack[5];

int top = -1;

void push(){

int x;

printf("Enter data: ");

scanf("%d",&x);

if(top==N-1)

printf("Overflow\n");

else{

top++;

stack[top]=x;

}

}