Dot product of matrix, MATLAB in Engineering

Dot Product:

The dot or inner product of two vectors a and b is written as a • b and is defined as 

793_dot product.png

In another words, this is like matrix multiplication when multiplying a row vector a by a column vector b; and the result is a scalar. This can be accomplished by using the * operator and transposing the second vector, or by using the dot function in a MATLAB:

>> vec1 = [4 2 5 1];

>> vec2 = [3 6 1 2];

>> vec1*vec2'

ans =

        31

>> dot(vec1,vec2)

ans =

        31

Posted Date: 10/22/2012 2:36:01 AM | Location : United States







Related Discussions:- Dot product of matrix, Assignment Help, Ask Question on Dot product of matrix, Get Answer, Expert's Help, Dot product of matrix Discussions

Write discussion on Dot product of matrix
Your posts are moderated
Related Questions
Comparing strings: There are few functions which compare strings and return logical true when they are equivalent or logical false when not. The function strcmp compares the s

Illustration of if - else statement: The one application of an if-else statement is to check for errors in the inputs to a script. For illustration, a former script prompted t

Example of Gauss-jordan: For a 2×2 system, this would results and for a 3 × 3 system, Note that the resulting diagonal form does not involve the right-most col

Execute a exponential function program: Running the script will take up the menu as shown in the figure: Then, what happens will totally depend on which button(s) the

Image Processing: The Images are represented as grids, or matrices, of picture elements (known as pixels). In MATLAB an image usually is represented as a matrix in which each

Defined a variable in work space: The variables defined in the script will become a part of the workspace: >> clear >> who >> mysummfile    15 >> who

Examine exponential function: The algorithm for the main script program is shown below:  Call a function eoption to show the menu and return the user's choice.  Loop

Algorithm for appex subfunction: The algorithm for appex subfunction is as shown:  Receives x & n as the input arguments.  Initializes a variable for running sum of t

Reading from a File in a While Loop: Though in most languages the combination of a loop and an if statement would be essential to determine whether or not the elements in a ve

Illustration of Set operations: For illustration, given the vectors as shown below: >> v1 = 2:6 v1 = 2  3  4  5  6 >> v2 = 1:2:7 v2 = 1  3  5  7