




已阅读5页,还剩9页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
num,data=xlsread(f:建模cumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xlsx)x=num(:,2)y=num(:,3)plot(x,y,r.)num1,data1=xlsread(f:建模cumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xlsx)num2,data2=xlsread(f:建模cumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xlsx,全市交通路口的路线)xyznpathnumz=data:,4dataz=data:,4data:,4datedataz=data(:,4)hold onfor i=1:length(x)if(strcmp(z(1),a)plot(x(i),y(i),.)endendhold onfor i=1:length(x)if(strcmp(z(1),a)plot(x(i),y(i),.)endendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.)endendz=z(2:end)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.)endendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.)endendnum1,data1=xlsread(c:usersyaokaiqiandesktopcumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xls)num2,data2=xlsread(c:usersyaokaiqiandesktopcumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xls,全市交通路口的路线)m=num1(:,6)m=num(:,6)num1,data1=xlsread(c:usersyaokaiqiandesktopcumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xls)m=num1(:,6)n=num1(:,7)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendendline1=num2(:,1)line2=num2(:,2)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endend %差一个点就ok了for i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendend -hold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendhold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endhold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endhold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);end -全图hold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endendfor i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endtmp=cat(2)tmp1=1;for i=1:length(line1)if(line1(i)=92)if(line2(i)=92)tmp(tmp1,1)=line1(i)tmp(tmp1,2)=line2(i)endendendxlswrite(tmp.xls,tmp)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endend-for i=1:length(line1)if(line1(i)=92)if(line2(i)=92) 连线line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendend-hold onfor i=1:length(x)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro); 描点 endif(n(i)=1)plot(x(i),y(i),r*);endend-for i=1:length(line1)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endtmp=cat(2)tmp1=1;for i=1:length(line1)if(line1(i)=92)if(line2(i)=92)tmp(tmp1,1)=line1(i)tmp(tmp1,2)=line2(i)endendendxlswrite(tmp.xls,tmp)clc;clearshapex = 413403383.5381339335317334.5333282247219225280290337415432418444251234225212227256250.5243246314315326327328336331371388.5411419411394342325315342345348.5351348370371354363357351369335381391392395398401405410408415418422418.5405.5405409417420424438438.5434438440447448444.5441440.5;shapey = 359343351377.5376383362353.5342325301316270292335328335371374394277271265290300301306328337367351355350342.5339334335330333330.5327.5344343346342348372374372382380.5377369363353374382.5387382388395381375366361362359360355350351347354356364.5368370364370372368373376385392381383385381.5;n=length(shapex);for i=1:nfor j=1:ndistance(i,j)=sqrt(shapex(i)-shapex(j)2+(shapey(i)-shapey(j)2);endenddistancea=zeros(n);max_value=zeros(n);for k=1:nmax_line,column=max(distance(k,:);a(k,column)=max_line;endmax_value(k,column)=max(max(a)i,j=find(max_value)point_start=shapex(i) shapey(i)point_end=shapex(j) shapey(j)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendhold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);if(m(i)=1)plot(x(i),y(i),ro);endif(n(i)=1)plot(x(i),y(i),r*);endtext(x(i),y(i),num2str(i);endendfor i=1:length(line1)if(line1(i)=92)if(line2(i)=92)line(x(line1(i),x(line2(i),y(line1(i),y(line2(i);endendendx=x=num(:,2)num2,data2=xlsread(c:usersyaokaiqiandesktopcumcm2011problems中文版bcumcm2011b附件2_全市六区交通网路和平台设置的数据表.xls)hold onfor i=1:length(x)if(strcmp(z(i),a)plot(x(i),y(i),.);i
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2025年第八届“人才·南平校园行”活动暨光泽县紧缺急需医疗人才引进考前自测高频考点模拟试题及答案详解(典优)
- 2025湖北咸宁市通城县城市发展建设投资(集团)有限公司招聘模拟试卷完整参考答案详解
- 2025湖北襄阳市枣阳市招聘事业单位人员206人模拟试卷附答案详解(模拟题)
- 2025广东广州市百万英才汇南粤广州中医药大学第三附属医院招聘14人考前自测高频考点模拟试题及答案详解(各地真题)
- 2025北京市海淀区中关村第二小学科学城北区分校招聘考前自测高频考点模拟试题及参考答案详解1套
- 2025江西交科交通工程有限公司招聘1人考前自测高频考点模拟试题及参考答案详解一套
- 2025广西贵港桂平市江口中心卫生院招聘3人模拟试卷及答案详解(新)
- Glutaryl-CoA-Glutarylcoenzyme-A-生命科学试剂-MCE
- 安全培训效果评价报告课件
- 广州资料员培训课件
- (完整)五年级上册生命与安全教案
- 从动态血压监测指南共识看高血压的管理课件
- 02项目一:02我国动车组的主要型号 (1)课件讲解
- 教科版科学四年级上册第一单元《声音》大单元整体教学设计
- 医院培训课件:《中医护理技术质量与安全管理》
- 历史课程中的跨学科教学与学科整合
- 技能培训资料:高压电动机线圈更换注意事项
- 移情训练法移情训练法
- 《大卫 科波菲尔(节选)》《复活》《老人与海》《百年孤独》 统编版高中语文选择性必修上册
- 2019版35kV输变电工程典型设计铁塔型录
- 展厅施工方案表
评论
0/150
提交评论