Added technical milestone report and changes to 1st presentation
[4yp.git] / chromaticDispersionTest.m
CommitLineData
1eeb62fb
AIL
1Rsym = 2.5e10; % symbol/sec
2sps = 4; % samples/symbol
3fs = Rsym * sps; % sampling freq (Hz)
4Tsamp = 1 / fs;
5
6x = 10 * normpdf(1:30, 10, 3);
7
8xCD = chromaticDispersion(x, 20, 1550, 30, Tsamp);
9
f9a73e9e
AIL
10figure(10001);
11subplot(121);
1eeb62fb
AIL
12plot(abs(x) .^ 2);
13axis([0 30 -Inf Inf]);
14title('Before dispersion');
15ylabel('Power (arb. unit)');
f9a73e9e
AIL
16xlabel('Time (arb. unit)');
17subplot(122);
1eeb62fb
AIL
18plot(abs(xCD) .^ 2)
19axis([20 50 -Inf Inf]);
20title('After dispersion');
f9a73e9e
AIL
21xlabel('Time (arb.~unit)');
22ylabel('Power (arb.~unit)');
23
24subplot(121);
25formatFigure;
26subplot(122)
27formatFigure;
28set(figure(10001), 'Units', 'centimeters', ...
29 'Position', [0 0 24 8], 'PaperPositionMode', 'auto');
30subplot(121);
31set(gca, 'XTick', 0:5:30);
32subplot(122);
33set(gca, 'XTick', 20:5:50);
1eeb62fb
AIL
34
35%saveas(gcf, 'dispersionTest.png');