Coordinate-conversion
坐标转换(四参数)
[row col]=size(source)
for i=1:row
u(i)=source(i,2)
v(i)=source(i,3)
x(i)=source(i,4)
y(i)=source(i,5)
B(2*i-1,1)=1
B(2*i-1,2)=0
B(2*i-1,3)=u(i)
B(2*i-1,4)=-v(i)
B(2*i,1)=0
B(2*i,2)=1
B(2*i,3)=v(i)
B(2*i,4)=u(i)
L(2*i-1,1)=x(i)
L(2*i,1)=y(i)
end
X=inv(B *B)*(B *L)
Txy=[X(1) X(2)]
xzjz(1,1)=X(3)
xzjz(1,2)=-X(4)
xzjz(2,1)=X(4)
xzjz(2,2)=X(3)
[row1 col1]=size(target)
for i=1:row1
u1(i)=target(i,2)
v1(i)=target(i,3)
d=[u1(i) v1(i)]
md=Txy+xzjz*d
end
end
(Coordinate conversion:
[row col]=size(source)
for i=1:row
u(i)=source(i,2)
v(i)=source(i,3)
x(i)=source(i,4)
y(i)=source(i,5)
B(2*i-1,1)=1
B(2*i-1,2)=0
B(2*i-1,3)=u(i)
B(2*i-1,4)=-v(i)
B(2*i,1)=0
B(2*i,2)=1
B(2*i,3)=v(i)
B(2*i,4)=u(i)
L(2*i-1,1)=x(i)
L(2*i,1)=y(i)
end
X=inv(B *B)*(B *L)
Txy=[X(1) X(2)]
xzjz(1,1)=X(3)
xzjz(1,2)=-X(4)
xzjz(2,1)=X(4)
xzjz(2,2)=X(3)
[row1 col1]=size(target)
for i=1:row1
u1(i)=target(i,2)
v1(i)=target(i,3)
d=[u1(i) v1(i)]
md=Txy+xzjz*d
end
end
)
- 2014-12-12 19:02:28下载
- 积分:1
MATLAB-Graphics
首先介绍MATLAB的基本知识及基本运算,使读者对MATLAB有一个概略的了解,然后系统论述图形绘制技术的基本概念、工作原理及在工程中的应用。书中精选科学和工程中常用的多个算法,全部采用MATLAB语言编程实现,并结合实例对算法程序进行验证和分析。其中详细讲解了MATLAB的基本知识、二维图形的绘制、三维图形的绘制、高级图形绘制技术、动画与视频、几何造型及GUI的程序设计等内容。(First introduced in MATLAB basic knowledge and basic operations, allowing the reader to have a rough understanding of MATLAB and then systematically discusses the basic concepts of graphics rendering technology, working principle and in engineering. The book featured commonly used in science and engineering multiple algorithms, all using MATLAB programming language, with examples for algorithm verification and analysis. Which explained in detail the basics of MATLAB, two-dimensional graphics rendering, 3D graphics rendering, advanced graphics rendering, animation and video, geometric modeling and GUI programming and other content.)
- 2013-11-13 20:57:06下载
- 积分:1