Matlab关于直线为轴对称与点为中心对称的图形代码 |
您所在的位置:网站首页 › 点关于直线对称点怎么算 › Matlab关于直线为轴对称与点为中心对称的图形代码 |
%% 直线为轴中心对称的圆 clc; clear; hold on syms x y; % 画对称轴 x1=-20:0.1:20; k=1; b1=10; f1(x)=k.*x+b1; plot(x1,f1(x1)); theta=0:2*pi/3600:2*pi; R=4; Circle1=10+R*cos(theta); Circle2=10+R*sin(theta); plot(Circle1,Circle2,'m','Linewidth',3); x1=Circle1; y1=Circle2; % 对称点坐标(2*x0-x1,2f(x0)-y1) b0=y1+(1/k).*x1; x0=(b0-b1).*(k/(k^2+1)); x2=2*x0-x1; y2=2*f1(x0)-y1; plot(x2,y2,'r-'); axis equal %% 直线为轴中心对称的三角形 close all; clear all; clc hold on x1=-20:0.1:20; syms x k=1/2; b1 |
今日新闻 |
点击排行 |
|
推荐新闻 |
图片新闻 |
|
专题文章 |
CopyRight 2018-2019 实验室设备网 版权所有 win10的实时保护怎么永久关闭 |