Matrices

Axy2ve in matlab

The following Matlab project contains the source code and Matlab examples used for axy2ve. AXY2VE Convert Graph of Adjacency Matrix and XY Points to Vertices and Edges Inputs:  A is a NxN adjacency matrix, where A(I,J) is nonzero  if and only if an edge connects point I to point J  xy is a Nx2 (or Nx3) matrix of x,y,(z) coordinates (equivalent to V) Outputs:  V is a Nx2 (or Nx3) matrix of x,y,(z) coordinates  E is a Px2 matrix containing a list of edge connections Example:  n = 10;  xy = 10*rand(n,2)  A = round(rand(n))  spy(A);  [V,E] = axy2ve(A,xy) Example:  n = 2e4;

Ve2axy in matlab

The following Matlab project contains the source code and Matlab examples used for ve2axy. VE2AXY Convert Graph of Vertices and Edges to Adjacency Matrix and XY Points Inputs:  V is a Nx2 (or Nx3) matrix of x,y,(z) coordinates  E is a Px2 matrix containing a list of edge connections Outputs:  A is a NxN adjacency matrix, where A(I,J) is nonzero  if and only if an edge connects point I to point J  xy is a Nx2 (or Nx3) matrix of x,y,(z) coordinates (equivalent to V) Example:  n = 10;  V = 10*rand(n,2)  E = ceil(n*rand(3*n,2))  [A,xy] = ve2axy(V,E)  spy(A); Example:  n = 2e4;

Ginv(x) in matlab

The following Matlab project contains the source code and Matlab examples used for ginv(x). Matlab's PINV(X) computes the Moore-Penrose generalized inverse of X, which is unique. Instead, GINV(X) computes any g-inverse of X. In fact, GINV returns a different g-inverse in each draw.

Kronecker tensor product in matlab

The following Matlab project contains the source code and Matlab examples used for kronecker tensor product. Kronecker product of the two matrix arguments in the order they appear If A is an m-by-n matrix and B is a p-by-q matrix, then the Kronecker product is the mp-by-nq block matrix    example, if X is 2 by 3, then KRONECKER(X,Y) is       [ X(1,1)*Y X(1,2)*Y X(1,3)*Y         X(2,1)*Y X(2,2)*Y X(2,3)*Y ] Thanks to Etienne Grossmann & Bruno Luong Mayowa.

Performs kmedioids clustering, requires only a nxn distance matrix d and number of clusters, k. in matlab

The following Matlab project contains the source code and Matlab examples used for performs kmedioids clustering, requires only a nxn distance matrix d and number of clusters, k. . Performs k-mediods clustering; only requires a distance matrix D and number of clusters k.

Plot 2 3d vector(s) in matlab

The following Matlab project contains the source code and Matlab examples used for plot 2 3d vector(s). QUIVERMD(AX, X, V, VARARGIN) plots the column vectors in matrix V at the points with coordinates the column vectors in matrix X, within axes object AX using plot formatting options in VARARGIN.

Calcuate euler angles from rotation matrix in matlab

The following Matlab project contains the source code and Matlab examples used for calcuate euler angles from rotation matrix. % This function return the rotation along x,y and z direction from a % Rotation Matrix %Inputs:     % R= 3x3 Rotation Matrix %Outputs:     % rx= Rotation along x direction in radians     % ry= Rotation along y direction in radians     % rz= Rotation along z direction in radians      % R = % % [ cos(ry)*cos(rz), -cos(ry)*sin(rz), sin(ry)]

Row column reduction coding in matlab

The following Matlab project contains the source code and Matlab examples used for row column reduction coding. Description: Row Column Reduction: Input: 8x8 block Output: Row reference vector(logical)8x1     Column reference vector(logical)1x8     Reduced matrix Row Column Expansion: Input: Row reference vector,column reference vector and reduced matrix Output: 8x8 block Reference:Saif Alzahir, “Color maps and graphs compression”, international conference on image processing, Hong Kong-September 2010  .

Pages

Subscribe to RSS - Matrices