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
function imread: The function imread can read an image file, for illustration a JPEG (.jpg) file. The function reads color images into a 3-dimensional matrix. >> myimage1

I have a vector of X, one for Y , one for x-direction velocity U and one for y-direction velocity V. they are at same size. How can I plot streamline of that flow? I follow all exa

I dont know how to input different videos on matlab program

num2str function: The num2str function, that converts real numbers, can be called in many ways. If only the real number is passed to the num2str function, it will generate a s

Illustration of initializing the data structure: illustration of initializing the data structure by preallocating is here as shown: >> cyls(3) = struct('code', 'c', 'dimen

Use of While loop: Here is an illustration of calling the function, passing 5000 for the value of the input argument high. >> factgthigh(5000) ans = 5040 The itera

Anonymous Functions: The anonymous function is a very easy, one-line function. The benefit of an anonymous function is that it does not have to be stored in an M-file. This ca

I have a 400x2 vel.dat and 20x2 xy.dat file, how can i plot a streamslice graph on matlab with this two files.

Use of Nested if-else statements: By using the nested if-else to select from among the three possibilities, not all the conditions should be tested. In this situation, if x is

Illustration of gauss-jordan: Here's an illustration of performing such substitutions by using MATLAB >> a = [1 3 0; 2 1 3; 4 2 3] a = 1 3 0 2 1 3 4 2