1 简介
随着科学技术的发展,计算机网络已是人们生活中无法离去的工具,故信息化彻底改变了人们的生活方式。数字图像处理也随之成为图像处理领域的首要之选。目前,MATLAB由于计算功能强大既支持数值运算又支持矩阵运算且便于用户二次开发,简单易学灵活性强,在数字图像处理领域的研究中成为了使用较为广泛的应用软件之一。
2 部分代码
function varargout = toneCure(varargin)%%% TONECURE MATLAB code for toneCure.fig% TONECURE, by itself, creates a new TONECURE or raises the existing% singleton*.%% H = TONECURE returns the handle to a new TONECURE or the handle to% the existing singleton*.%% TONECURE('CALLBACK',hObject,eventData,handles,...) calls the local% function named CALLBACK in TONECURE.M with the given input arguments.%% TONECURE('Property','Value',...) creates a new TONECURE or raises the% existing singleton*. Starting from the left, property value pairs are% applied to the GUI before toneCure_OpeningFcn gets called. An% unrecognized property name or invalid value makes property applicationif (get(handles.pushbutton6, 'Value') >0 )cla(handles.axes2,'reset');cla(handles.axes3,'reset'); % 重置清空动态axes1的数据cla(handles.axes4,'reset'); % 重置清空动态axes1的数据set(handles.edit1,'string','');set(handles.edit2,'string',''); % 清空framset(handles.edit3,'string',''); % 清空framset(handles.popupmenu1,'Value',1); %选择菜单set(handles.popupmenu4,'Value',1);points(1,1:2)=0.0;points(2,1:2)=0.2;points(3,1:2)=0.4;points(4,1:2)=0.6;points(5,1:2)=0.8;points(6,1:2)=1;p1 = polyfit(points(:,1), points(:,2), 5); %% y = x + b;x=0:0.01:1;y = polyval(p1, x);% hold on;y2 = x ;plot(x, y2, 'k-.', 'LineWidth', 1, 'parent', handles.axes2);hold on;plot(x, y, 'r-', points(:,1), points(:,2), 'b*', 'LineWidth', 1.25, 'parent', handles.axes2) ;legend('y = x', 'y = f(x)', 'Location', 'northwest');grid on;idx=0;end% Update handles structureguidata(hObject, handles);
3 仿真结果
4 参考文献
[1]英英. 基于MATLAB的图形图像处理系统的实现[D]. 内蒙古大学, 2013.
博主简介:擅长智能优化算法、神经网络预测、信号处理、元胞自动机、图像处理、路径规划、无人机等多种领域的Matlab仿真,相关matlab代码问题可私信交流。
部分理论引用网络文献,若有侵权联系博主删除。
版权声明:本文为matlab_dingdang原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。