-
大小: 636KB文件类型: .zip金币: 2下载: 0 次发布日期: 2024-01-27
- 语言: Matlab
- 标签: 四元数 Matlab quaternion
资源简介
Quaternion toolbox for Matlab is a toolbox that extends Matlab to handle matrices of quaternions with real and complex components. Many Matlab operators and functions are overloaded to work for real quaternion and complexified quaternion matrices.

代码片段和文件信息
function [U B V] = bidiagonalize(A)
% Bidiagonalize A such that U * A * V = B and U‘ * B * V‘ = A. B is the
% same size as A has no vector part and is upper or lower bidiagonal
% depending on its shape. U and V are unitary quaternion matrices.
% Copyright ?2005 2008 Stephen J. Sangwine and Nicolas Le Bihan.
% See the file : Copyright.m for further details.
error(nargchk(1 1 nargin)) error(nargoutchk(3 3 nargout))
% References:
%
% Sangwine S. J. and Le Bihan N.
% Quaternion singular value decomposition based on bidiagonalization
% to a real or complex matrix using quaternion Householder transformations
% Applied Mathematics and Computation 182(1) 1 November 2006 727-738
% DOI:10.1016/j.amc.2006.04.032.
%
% Sangwine S. J. and Le Bihan N.
% Quaternion Singular Value Decomposition based on Bidiagonalization
% to a Real Matrix using Quaternion Householder Transformations
% arXiv:math.NA/0603251 10 March 2006 available at http://www.arxiv.org/
%
% Gene H. Golub and Charles van Loan ‘Matrix Computations‘ 3rd edition
% Johns Hopkins University Press 1996 section 5.1.4. ISBN 0-8018-5414-8.
% (This describes how to implement a Householder transformation without an
% explicit Householder matrix.)
[r c] = size(A);
if prod([r c]) == 1
error(‘Cannot bidiagonalize a matrix of one element.‘);
end
if c <= r
[U B V] = internal_bidiagonalizer(A); % Upper bidiagonal result.
else
% This requires a lower bidiagonal result. We handle this by operating
% on the Hermitian transpose of A. The results require some swapping
% and transposition to get the correct results.
[V B U] = internal_bidiagonalizer(A‘); U = U‘; B = B.‘; V = V‘;
end
B = check(B); % Verify the result and convert to exactly bidiagonal form
% with a real or complex B.
% -------------------------------------------------------------------------
function [U B V] = internal_bidiagonalizer(A)
[r c] = size(A); assert(c <= r);
% Iterate over the whole matrix dealing with one column and one row on
% each pass through the loop. See Figure 1 in the Applied Mathematics and
% Computation paper cited above for a diagrammatic representation of this
% process.
U = eyeq(r); % Initialise the three matrix results to appropriately sized
B = A; % quaternion matrices. These are conformant so that U * B * V
V = eyeq(c); % has the same size as A.
for i = 1:c
% Compute and apply a left Householder transformation to the ith
% column (part of the column for the second and subsequent columns).
[h zeta] = householder_vector(B(i:end i) eye(r - i + 1 1));
T = B(i:end i:end); B(i:end i:end) = (1./zeta) .* (T - h * (T‘ * h)‘);
T = U(i:end : ); U(i:end : ) = (1./zeta) .* (T - h * (T‘ * h)‘);
if i == c return; end % On the last column we are done since there
% is no corresponding row. See Figure 1 in the
% Applied Mathematics
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 369 2010-05-24 21:02 qtfm\DEsc
文件 269 2010-05-24 20:43 qtfm\COPYING
文件 155 2010-05-24 20:56 qtfm\INDEX
文件 1531 2010-07-05 20:41 qtfm\set_octave_path.m
文件 637 2010-12-19 17:06 qtfm\@quaternion\abs.m
文件 916 2009-02-08 18:35 qtfm\@quaternion\acos.m
文件 943 2009-02-08 18:35 qtfm\@quaternion\acosh.m
文件 9034 2010-06-28 20:08 qtfm\@quaternion\adjoint.m
文件 5291 2010-11-04 21:49 qtfm\@quaternion\angle.m
文件 569 2009-12-23 18:21 qtfm\@quaternion\arrayfun.m
文件 912 2009-02-08 18:35 qtfm\@quaternion\asin.m
文件 939 2009-02-08 18:35 qtfm\@quaternion\asinh.m
文件 918 2009-02-08 18:35 qtfm\@quaternion\atan.m
文件 945 2009-02-08 18:35 qtfm\@quaternion\atanh.m
文件 1532 2009-11-12 19:45 qtfm\@quaternion\axis.m
文件 1785 2010-12-19 17:42 qtfm\@quaternion\blkdiag.m
文件 2405 2010-05-13 20:22 qtfm\@quaternion\bsxfun.m
文件 490 2009-02-08 18:35 qtfm\@quaternion\cast.m
文件 2320 2010-12-19 17:07 qtfm\@quaternion\cat.m
文件 916 2009-02-08 18:35 qtfm\@quaternion\cd.m
文件 6595 2010-12-19 17:08 qtfm\@quaternion\cdpolar.m
文件 378 2009-02-08 18:35 qtfm\@quaternion\ceil.m
文件 1384 2010-11-04 21:49 qtfm\@quaternion\change_basis.m
文件 2711 2010-11-04 21:50 qtfm\@quaternion\char.m
文件 650 2009-12-10 17:11 qtfm\@quaternion\complex.m
文件 1179 2009-02-08 18:35 qtfm\@quaternion\conj.m
文件 8847 2009-02-08 18:35 qtfm\@quaternion\conv.m
文件 7751 2009-02-08 18:35 qtfm\@quaternion\conv2.m
文件 925 2010-12-19 17:09 qtfm\@quaternion\convert.m
文件 943 2011-01-08 21:14 qtfm\@quaternion\cos.m
文件 947 2009-02-08 18:35 qtfm\@quaternion\cosh.m
............此处省略518个文件信息
- 上一篇:madgwick_传感器融合算法_matlab
- 下一篇:ieee14节点的潮流计算
相关资源
- matlab_OFDM调制解调(来自剑桥大学)
- Matlab路面裂缝识别69319
- 高灵敏度GPS接收机MATLAB仿真,附捕获
- 基于MATLAB的质点弹道计算与外弹道优
- 阵列天线的matlab仿真
- MATLAB 经典程序源代码大全
- MATLAB小波软阈值去噪代码33473
- 天线阵的波束形成在MATLAB仿真程序及
- 非线性SVM算法-matlab实现
- 《MATLAB 智能算法超级学习手册》-程序
- 组合导航matlab程序
- 读取txt文件内容matlab代码实现
- Matlab实现基于相关的模板匹配程序
- matlab优化工具箱讲解
- 基于MATLAB的快速傅里叶变换
- 光纤传输中的分布傅立叶算法matlab实
- 基于matlab的图像处理源程序
- matlab 椭圆拟合程序
- 算术编码解码matlab源代码
- optical_flow 光流法 matlab 实现程序
- 引导图像滤波器 Matlab实现
- 分形几何中一些经典图形的Matlab画法
- OFDM系统MATLAB仿真代码
- SVM工具箱(matlab中运行)
- 图像小波变换MatLab源代码
- LU分解的MATLAB实现
- 冈萨雷斯数字图像处理matlab版(第三
- 替代数据法的matlab程序
- 用matlab实现的多站定位系统性能仿真
- 通过不同方法进行粗糙集属性约简m
评论
共有 条评论