Communication Theory Lab (1)

Slides:



Advertisements
Similar presentations
Introduction to Matlab
Advertisements

CS433: Modeling and Simulation
Probability Distribution
ฟังก์ชั่นการแจกแจงความน่าจะเป็น แบบไม่ต่อเนื่อง Discrete Probability Distributions.
Lecture (10) Mathematical Expectation. The expected value of a variable is the value of a descriptor when averaged over a large number theoretically infinite.
Continuous Random Variable (1). Discrete Random Variables Probability Mass Function (PMF)
Review of Basic Probability and Statistics
Probability Distributions Finite Random Variables.
UNR, MATH/STAT 352, Spring Random variable (rv) – central concept of probability theory Numerical description of experiment.
Continuous Random Variables and Probability Distributions
5-1 Two Discrete Random Variables Example Two Discrete Random Variables Figure 5-1 Joint probability distribution of X and Y in Example 5-1.
5-1 Two Discrete Random Variables Example Two Discrete Random Variables Figure 5-1 Joint probability distribution of X and Y in Example 5-1.
Modern Navigation Thomas Herring
Econ 482 Lecture 1 I. Administration: Introduction Syllabus Thursday, Jan 16 th, “Lab” class is from 5-6pm in Savery 117 II. Material: Start of Statistical.
Discrete Probability Distributions A sample space can be difficult to describe and work with if its elements are not numeric.A sample space can be difficult.
Chapter 5 Discrete Probability Distribution I. Basic Definitions II. Summary Measures for Discrete Random Variable Expected Value (Mean) Variance and Standard.
Prof. SankarReview of Random Process1 Probability Sample Space (S) –Collection of all possible outcomes of a random experiment Sample Point –Each outcome.
OUTLINE Probability Theory Linear Algebra Probability makes extensive use of set operations, A set is a collection of objects, which are the elements.
TELECOMMUNICATIONS Dr. Hugh Blanton ENTC 4307/ENTC 5307.
Statistics for Engineer Week II and Week III: Random Variables and Probability Distribution.
Moment Generating Functions
Recap Script M-file Editor/Debugger Window Cell Mode Chapter 3 “Built in MATLAB Function” Using Built-in Functions Using the HELP Feature Window HELP.
STA347 - week 51 More on Distribution Function The distribution of a random variable X can be determined directly from its cumulative distribution function.
2.1 Introduction In an experiment of chance, outcomes occur randomly. We often summarize the outcome from a random experiment by a simple number. Definition.
Lecture PowerPoint Slides Basic Practice of Statistics 7 th Edition.
Computer Vision Group Prof. Daniel Cremers Autonomous Navigation for Flying Robots Lecture 5.2: Recap on Probability Theory Jürgen Sturm Technische Universität.
Recap Sum and Product Functions Matrix Size Function Variance and Standard Deviation Random Numbers Complex Numbers.
1 Since everything is a reflection of our minds, everything can be changed by our minds.
The two way frequency table The  2 statistic Techniques for examining dependence amongst two categorical variables.
Tim Marks, Dept. of Computer Science and Engineering Random Variables and Random Vectors Tim Marks University of California San Diego.
DISCRETE RANDOM VARIABLES.
EQT 272 PROBABILITY AND STATISTICS
Matlab Screen  Command Window  type commands  Current Directory  View folders and m-files  Workspace  View program variables  Double click on a.
Random Variables (1) A random variable (also known as a stochastic variable), x, is a quantity such as strength, size, or weight, that depends upon a.
Probability Refresher COMP5416 Advanced Network Technologies.
Probability Review-1 Probability Review. Probability Review-2 Probability Theory Mathematical description of relationships or occurrences that cannot.
EEE Probability and Random Variables Huseyin Bilgekul EEE 461 Communication Systems II Department of Electrical and Electronic Engineering Eastern.
CONTINUOUS RANDOM VARIABLES
Probability Theory Modelling random phenomena. Permutations the number of ways that you can order n objects is: n! = n(n-1)(n-2)(n-3)…(3)(2)(1) Definition:
Random Variables. Numerical Outcomes Consider associating a numerical value with each sample point in a sample space. (1,1) (1,2) (1,3) (1,4) (1,5) (1,6)
Continuous Random Variables and Probability Distributions
CSE 474 Simulation Modeling | MUSHFIQUR ROUF CSE474:
PATTERN RECOGNITION LAB 2 TA : Nouf Al-Harbi::
Probability & Random Variables
Random Variables By: 1.
12.SPECIAL PROBABILITY DISTRIBUTIONS
L Basic Definitions: Events, Sample Space, and Probabilities l Basic Rules for Probability l Conditional Probability l Independence of Events l Combinatorial.
Probability and Information Theory
Linear Algebra Review.
Oliver Schulte Machine Learning 726
Random Variable 2013.
Introduction to MATLAB
Math a Discrete Random Variables
Computer Application in Engineering Design
CONTINUOUS RANDOM VARIABLES
Chapter Four Random Variables and Their Probability Distributions
Review of Probability Theory
MATLAB DENC 2533 ECADD LAB 9.
Chapter. 5_Probability Distributions
Introduction to Matlab
3.1 Expectation Expectation Example
MATLAB Tutorial Dr. David W. Graham.
Probability Review for Financial Engineers
Advanced Artificial Intelligence
Continuous Random Variable Normal Distribution
How to Use MATLAB A Brief Introduction.
Lectures prepared by: Elchanan Mossel Yelena Shvets
RANDOM VARIABLES Random variable:
M248: Analyzing data Block A UNIT A3 Modeling Variation.
Chapter 5: Discrete Probability Distributions
Presentation transcript:

Communication Theory Lab (1) Prepared by: Eng.Lamiaa Daoud

Agenda MATLAB Revision Random Variable Definition Types of Random Variables Types and Features Task

Variables: ∞ π Syntax Description X=6 Integer Y=[1 2 3 4] Vector Z=[1 3 8 7;5 2 4 3 ] Matrix L=3+4i Complex number M=‘hello’ String R=Inf ∞ S=pi π

Exponential Functions: Syntax Description a^b ab exp(a) ea log10(a) log10 a log2(a) log2 a log(a) ln a sqrt(a)

Vectors: Description Output Syntax X=[1 3 5 7 9] X=[x1 x2 x3 x4 x5] X=start: step: end Y=X(2) Y=2nd element in X Y=3 X(3)=4 Set the 3rd element in X to 4 X=[1 3 4 7 9] Y=X(2:1:3) Y=2nd to 3rd element in X Y=[3 4] Y=X(1:2:end) Y=1st to last element in X with a step of 2 Y=[1 4 9] Y=X(5:-2:2) Y=5th to 2nd element in X with a step of -2 Y=[9 4 ] Y=X([2 3 5]) Y=2nd 3rd and 5th elements in X Y=[3 4 9]

Y= Conjugate transpose of X in case of complex numbers Vectors: Syntax Description Output Y=X.’ Y=transpose of X Y=[1 3 4 7 9] Y=X’ Y= Conjugate transpose of X in case of complex numbers Y=X.^2 Y=[x12 x22 x32 x42 x52] Y=[1 9 16 49 81]

Vectors: Description Output Syntax Y=length(X) Y=number of elements in X Y=5 Y=sum(X) Y=sum of elements of X Y=24 Y=mean(X) Y=sum(X)/length(X) Y=24/5 =4.8 Y=find(X==4) Y=location of element 5 in X Y=3 Y=find(X>5) Y=location of elements >5 in X Y=[4 5] Y=find(X>5 & X<9) Y=location of elements >5 and <9 in X Y=[4] Y=find(X<3 |X>5) Y=location of elements <3and >9 in X Y=[1 4 5 ]

Plotting Description X=[x1 x2 x3 x4 x5…………xn] Y=[y1 y2 y3 y4 y5…………yn] Syntax Description X=[x1 x2 x3 x4 x5…………xn] Y=[y1 y2 y3 y4 y5…………yn] plot(X,Y) Define both vectors then plot X=-pi:0.01*pi:pi; Y=sin(X); Define one vector and define the other as a function of it xlabel(‘x’) label the x axis ylabel(‘sin(x)’) label the y axis title(‘Sine Wave’) Give a title hold on /hold off Plot more than one graph in the same figure figure Create a new figure legend(‘str1’,’str2’,…..) Display a legend

Help:

Help: Type the functionality you are searching for

Notes: Matlab is case sensetive which means that X is not equivalent to x. Typing a ; at the end of every command means not to display the values in the command window after executing the command. Typing a % before a command means it is a comment and the program will not execute it.

Random Experiment It is an experiment whose outcome cannot be predicted with certainty Examples: Tossing a Coin Rolling a Die

Random Variable Definition A variable that results due to a random process Example: Rolling a dice Tossing a coin

Types of Random variables Discrete Random Variables The random variable can only take a finite number of values (ex: tossing a coin) Continuous Random Variables The random variable can take a continous of values (phase of the carrier)

Mean of a Random Variable Discrete Random Variable Continuous Random Variable

Mean of Discrete Random Variable Probability mass function P[X=x] Mean: Weighted average

Probability Density Functions: (Continuous random variables) A probability density function: gives the probability that a random variable x takes on values within a range. Probability density f(x) Properties of probability density function: 0 a b 17

Variance of the random variable Variance is a measure of the randomness of the random variable i.e it is a measure of the amount of variation within the values of the random variable.

Variance of the random variable Discrete Random Variable: Continuous Random Variable:

Example: Gaussian Random Variable Probability density function: Where is the mean of the random variable x. is the variance of x.

Gaussian (Normal) RV m: mean : variance

Task 1 It is required to generate 1000 normally distributed samples with mean 3 and variance 2 Add the previous samples to another 1000 normally distributed samples with mean 4 and variance 3 Get the mean and the variance of the resulted signal What do you notice ?

Variancetotal = Variance1 + Variance2 meantotal = mean1 + mean2

Task 2 Plot the probability density functions of the previous example on the same graph Notice the mean of the plotted functions from the graph

Useful Commands normrnd(mean, standard deviation, number of rows, number of columns)