I need help integrating to find the PDF CDF in MATLAB. (a)
Below is the Matlab Code
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
close all,
clear all,
clc,
a = -0.5;
b = 0.5;
x_1=[];
x_2=[];
x_3=[];
x_4=[];
x_5=[];
x_6=[];
Y_1=[];
y_2=[];
for i=1:10000
x_1(i) = (b-a)*rand + a;
x_2(i) = (b-a)*rand + a;
x_3(i) = (b-a)*rand + a;
x_4(i) = (b-a)*rand + a;
x_5(i) = (b-a)*rand + a;
x_6(i) = (b-a)*rand + a;
y_1(i) = x_1(i) + x_2(i) + x_3(i) + x_4(i) + x_5(i) + x_6(i);
y_2(i) = x_1(i) + (0.5*x_2(i)) + (0.8*x_3(i)) + (1.8*x_4(i)) +
(0.3*x_5(i)) + (0.5*x_6(i));
end
subplot(3,2,1); plot(x_1); title('X1');
subplot(3,2,2); plot(x_2); title('X2');
subplot(3,2,3); plot(x_3); title('X3');
subplot(3,2,4); plot(x_4); title('X4');
subplot(3,2,5); plot(x_5); title('X5');
subplot(3,2,6); plot(x_6); title('X6');
figure,
subplot(2,1,1); hist(y_1,20); title('PDF - Y1');
subplot(2,1,2); hist(y_2,20); title('PDF - Y2');
figure,
subplot(2,1,1); cdfplot(y_1); title('CDF - Y1');
subplot(2,1,2); cdfplot(y_2); title('CDF - Y2');
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
I need help integrating to find the PDF CDF in MATLAB. (a) 1. Generate six sequences of uniform random variables (length 10,000) in the range [-0.5,0.5]. Each element in the ith sequence can be consi...