Beruflich Dokumente
Kultur Dokumente
Communications
Homework 01
Contents
1 SECTION
1.1 Q1 . .
1.2 Q2 . .
1.3 Q3 . .
1.4 Q4 . .
1.5 Q5 . .
1.6 Q6 . .
1.7 Q7 . .
1.8 Q8 . .
A
. .
. .
. .
. .
. .
. .
. .
. .
.
.
.
.
.
.
.
.
1
1
1
2
2
3
3
4
4
2 SECTION B
2.1 Q1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2.2 Q2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
5
5
6
3 SECTION C
3.1 Q1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
3.2 Q2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
6
6
6
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
1
1.1
SECTION A
Q1
urn = {R1,R2,R3,R4,BK1,BK2,BK3}
R stands for RED, BK stands for BLACK
1.2
Q2
P (Ei ) =
# possible outs f or Ei
# outs of
3
7
3
P (E2 ) =
7
4
P (E3 ) =
7
5
P (E4 ) =
7
P (E1 ) =
1.3
Q3
(1 p) p0
(1 p) p0 + p p1
b. P (A1 /B1 ) ?
1 )P (A1 )
P (A1 /B1 ) = P (B1 /A
P (B1 )
P (B1 ) = P (B1 /A0 ) P (A0 ) + P (B1 /A1 ) P (A1 )
P (B1 ) = p p0 + (1 p) p1
P (A1 /B1 ) =
1.4
(1 p) p1
p p0 + (1 p) p1
Q4
A
R function is a probability density function if:
f (x)dx = 1
x
So:
R1 c
R1
dx =
c x0.5 dx = 2cx0.5 |10 = 2c = 1
0
0
x
c=
1
2
1.5
Q5
a.
A
R function is a probability density function if:
f (x)dx = 1
x
So:
R x
e
dx = ex |
0 = (0 1) = 1
0
b.
Rx
Rx
Fx (x) = fx (x)dx = 0 ex dx = ex |x0 = (ex 1) = 1 ex
1.6
Q6
R
= xfx (x)dx
and
R
V AR = (x )2 fx (x)dx
So: R
R
R0
R
R
0
= xfx (x)dx = 12 xex dx+ 0 21 xex dx = 12 xex dx + 0 xex dx
Using integration
by parts:
R
R
0
=
= 12 xex dx + 0 xex dx = 12 (xex 2 ex )0 + (xex 2 ex )
0
0
=0
R
R0
R
R
V AR = (x)2 fx (x)dx = x2 fx (x)dx = 12 x2 ex dx+ 0 21 x2 ex dx
Integration
by parts: R
R
R0
R
2
(x
)
fx (x)dx = x2 fx (x)dx = 12 x2 ex dx + 0 12 x2 ex dx =
h
0
i
1
x2 ex 22 xex + 23 ex + x2 ex 22 xex 23 ex 0 =
2
3
1
3
4
2 (2 0) + (0 + 2 ) = 2
V AR = 24
1.7
Q7
We have that:
R
y 2
Q(x) = x 12 e 2 dy
erfc(x) = 1 a.
1
2
Rx
2
1 ey dy
erfc x2 =
1
2
R
x
2
2 ey dy
2
2 ey dy
2
1 ey dy
u=y 2
So:
R
2
1 ey dy
1
2
b.
R
2Q( 2x) = 2 2x
R
x
2
1 eu /2 du
y
1 e 2
2
R
x
2
1 eu /2 du
2
= Q(x)
dy
y
1 e 2
2
1.8
R
dy = 2 2 x
2
1 eu du
2
R
x
2
2 eu du
= erf c(x)
Q8
R 2
Rx ( ) = 0 Acos(F t + )Acos(F (t + ) + )d
Trigonometry property:
cos(A)cos(B) = 21 (cos(A + B) + cos(A B))
2 R 2
Rx ( ) = A2 0 [cos(2F t + F + 2) + cos(F )] d =
A2
2
R 2
0
cos(F )d =
Rx ( ) = 2
A2
2
R 2
0
A2
2
Z
|0
cos(2F t + F + 2) d+
{z
}
0
cos(F )d
A2
cos(F )
2
2
Sx (f ) = 2
A2
F
F [cos(2
)]
2
2
If F is constant:
2
Sx (f ) = 2 A2 F [cos(2 F2 )] = 2 A2 12 ((f
F
F
2 ) + (f + 2 ))
Sx (f ) =
2
2.1
F
2 )
+ (f +
A2
F
F
((f
) + (f +
))
2
2
2
SECTION B
Q1
AM
b - Power: P =
A2
2
+ 12 |x2 (t)|
FM
b - Power:
A2
2
c - Bandwith: 2(f + fm )
PM
b - Power:
A2
2
F
2 ))
A2
2 ((f
2.2
Q2
DSB-SC2 AM
Pm
S
N
= Ac
2W N0
DSB-SC2 AM
Pm
S
N
= Ac
W N0
DSB-SC2 AM
2
S
N
= kp 2Ac NP0mW
DSB-SC2 AM
Ac2 Pm
S
N
= 3kp
2W 2 N0 W
* From the textbook
3
3.1
SECTION C
Q1
* TA MATLAB code
1
2
m = 1;
sgma = 2 ;
3
4
5
6
7
8
N=10000;
u=rand (N, 1 ) ; % a uniform random v a r i a b l e i n ( 0 , 1 )
%z=sgma ( s q r t ( 2 l o g (1/(1. u ) ) ) ) ; % a R a y l e i g h d i s t r i b u t e d
random v a r i a b l e
u = 1u ;
u 2 = 1+u ;
9
10
11
12
13
z = sgma ( s q r t ( 2 l o g ( 1 . / u 2 ) ) ) ;
v=rand (N, 1 ) ; % a n o t h e r uniform random v a r i a b l e i n ( 0 , 1 )
g s r v 1=m+z . c o s ( 2 p i v ) ;
g s r v 2=m+z . s i n ( 2 p i v ) ;
14
15
16
17
h i s t ( gsrv1 , 2 0 )
plot ( gsrv1 )
3.2
Q2
1
2
%Q3
3
4
5
6
7
8
9
% 1
% data from t h e problem
t0 = 0 . 1 ;
fc = 250;
t s = 1 e 4;
kf = 100;
10
11
12
13
14
%
t
p
p
c r e a t i n g t h e time v e c t o r
= 0 : t s : ( 2 t 0 )t s ;
= s i z e ( t 0+t s : t s : ( 2 t 0 )t s ) ;
= p(1 ,2) ;
15
16
17
18
19
20
21
22
23
24
25
m = [ s i n c ( k f [ 0 : t s : t 0 ] ) z e r o s ( 1 , p ) ] ; %d e f i n i t i o n o f m( t )
Im = t s cumtrapz (m) ; %i n t e g r a l o f m( t )
%m = s i n ( 1 0 0 t ) ;
subplot (2 ,1 ,1)
p l o t ( t ,m) ; % p l o t m
y l a b e l ( m( t ) ) ;
subplot (2 ,1 ,2) ;
p l o t ( t , Im ) ; % p l o t m i n t e g r a l
y l a b e l ( I n t e g r a l o f m( t ) ) ;
x l a b e l ( time ) ;
26
27
28
29
30
31
32
33
34
% 2
t 2 = l i n s p a c e ( 0 , t0 , 2 0 0 0 ) ; % c r e a t i n g t h e time v e c t o r
ts2 = ( t0 0) /1999; % determining the sampling r a t e
u = c o s ( 2 p i f c t 2 + 2 p i k f cumtrapz ( t s 2 ( 2 p i f c t 2 ) ) ) ;
%u s i n g t h e d e f i n i t i o n o f u
figure ()
p l o t ( t2 , u ) ; %p l o t i n g u
x l a b e l ( time ) ;
ylabel ( u( t ) ) ;
35
36
37
38
39
40
41
42
43
44
45
% 3
L1 = l e n g t h (m) ;
L2 = l e n g t h ( u ) ;
Y1 = abs ( f f t (m) ) /L1 ;
Y2 = abs ( f f t ( u ) ) /L2 ;
Y11 = Y1 ( 1 : L1/2+1) ;
Y22 = Y2 ( 1 : L2/2+1) ;
f 1 = ( 1 / t s ) ( 0 : L1 / 2 ) /L1 ;
f 2 = ( 1 / t s 2 ) ( 0 : L2 / 2 ) /L2 ;
figure ()
7
46
47
48
49
subplot (2 ,1 ,1)
p l o t ( f1 , Y11 ) ;
subplot (2 ,1 ,2) ;
p l o t ( f2 , Y22 ) ;