⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 planar_array_gui.m

📁 matlab的雷达相关程序
💻 M
📖 第 1 页 / 共 2 页
字号:
function varargout = planar_array_gui(varargin)
% PLANAR_ARRAY_GUI M-file for planar_array_gui.fig
%      PLANAR_ARRAY_GUI, by itself, creates a new PLANAR_ARRAY_GUI or raises the existing
%      singleton*.
%
%      H = PLANAR_ARRAY_GUI returns the handle to a new PLANAR_ARRAY_GUI or the handle to
%      the existing singleton*.
%
%      PLANAR_ARRAY_GUI('CALLBACK',hObject,eventData,handles,...) calls the local
%      function named CALLBACK in PLANAR_ARRAY_GUI.M with the given input arguments.
%
%      PLANAR_ARRAY_GUI('Property','Value',...) creates a new PLANAR_ARRAY_GUI or raises the
%      existing singleton*.  Starting from the left, property value pairs are
%      applied to the GUI before planar_array_gui_OpeningFunction gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to planar_array_gui_OpeningFcn via varargin.
%
%      *See GUI Options on GUIDE's Tools menu.  Choose "GUI allows only one
%      instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES

% Edit the above text to modify the response to help planar_array_gui

% Last Modified by GUIDE v2.5 13-Jun-2003 14:44:11
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @planar_array_gui_OpeningFcn, ...
                   'gui_OutputFcn',  @planar_array_gui_OutputFcn, ...
                   'gui_LayoutFcn',  [] , ...
                   'gui_Callback',   []);
if nargin & isstr(varargin{1})
   gui_State.gui_Callback = str2func(varargin{1});
end

if nargout
   [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
   gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT


% --- Executes just before planar_array_gui is made visible.
function planar_array_gui_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
% varargin   command line arguments to planar_array_gui (see VARARGIN)

% Choose default command line output for planar_array_gui
handles.output = hObject;

% Update handles structure
guidata(hObject, handles);

% UIWAIT makes planar_array_gui wait for user response (see UIRESUME)
% uiwait(handles.figure1);


% --- Outputs from this function are returned to the command line.
function varargout = planar_array_gui_OutputFcn(hObject, eventdata, handles)
% varargout  cell planar_array_gui for returning output args (see VARARGOUT);
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure
varargout{1} = handles.output;



% initialization values
data.Nx = 51 ;
data.Ny = 21 ;
data.Ncirc = 51 ;
data.dolxr = 0.5 ;
data.dolyr = 0.5 ;
data.theta0 = 20 ;
data.phi0 = 30 ;
data.nbits = -1 ;
data.winchoice = 1 ; % 1=none, 2=Hamming, 3=Hanning, 4=Kaiser, 5=Blackman
data.arraychoice = 1 ; % 1=rectangular, 2=circular, 3 = triangular


set(handles.Nx,'String', num2str(51)) ;
set(handles.Ny,'String', num2str(21)) ;
set(handles.Ncirc,'String', num2str(51)) ;
set(handles.dolxr,'String', num2str(0.5)) ;
set(handles.dolyr,'String', num2str(0.5)) ;
set(handles.theta0,'String', num2str(20)) ;
set(handles.phi0,'String',num2str(30)) ;
set(handles.nbits,'String',num2str(-1)) ;

set(handles.Nx,'Enable','on');        
set(handles.Ny, 'Enable','on') ;
set(handles.Ncirc,'Enable','off');
      
% --- Executes during object creation, after setting all properties.function Nx_CreateFcn(hObject, eventdata, handles)% hObject    handle to Nx (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    empty - handles not created until after all CreateFcns called% Hint: edit controls usually have a white background on Windows.%       See ISPC and COMPUTER.if ispc   set(hObject,'BackgroundColor','white');else   set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));endfunction Nx_Callback(hObject, eventdata, handles)% hObject    handle to Nx (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% Hints: get(hObject,'String') returns contents of Nx as text%        str2double(get(hObject,'String')) returns contents of Nx as a double




% --- Executes during object creation, after setting all properties.function Ny_CreateFcn(hObject, eventdata, handles)% hObject    handle to Ny (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    empty - handles not created until after all CreateFcns called% Hint: edit controls usually have a white background on Windows.%       See ISPC and COMPUTER.if ispc   set(hObject,'BackgroundColor','white');else   set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));endfunction Ny_Callback(hObject, eventdata, handles)% hObject    handle to Ny (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% Hints: get(hObject,'String') returns contents of Ny as text%        str2double(get(hObject,'String')) returns contents of Ny as a double









% --- Executes during object creation, after setting all properties.
function Ncirc_CreateFcn(hObject, eventdata, handles)
% hObject    handle to Ncirc (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: edit controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc
    set(hObject,'BackgroundColor','white');
else
    set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));
end



function Ncirc_Callback(hObject, eventdata, handles)
% hObject    handle to Ncirc (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'String') returns contents of Ncirc as text
%        str2double(get(hObject,'String')) returns contents of Ncirc as a double









% --- Executes during object creation, after setting all properties.function dolxr_CreateFcn(hObject, eventdata, handles)% hObject    handle to dolxr (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    empty - handles not created until after all CreateFcns called% Hint: edit controls usually have a white background on Windows.%       See ISPC and COMPUTER.if ispc   set(hObject,'BackgroundColor','white');else   set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));endfunction dolxr_Callback(hObject, eventdata, handles)% hObject    handle to dolxr (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% Hints: get(hObject,'String') returns contents of dolxr as text%        str2double(get(hObject,'String')) returns contents of dolxr as a double















% --- Executes during object creation, after setting all properties.function dolyr_CreateFcn(hObject, eventdata, handles)% hObject    handle to dolyr (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    empty - handles not created until after all CreateFcns called% Hint: edit controls usually have a white background on Windows.%       See ISPC and COMPUTER.if ispc   set(hObject,'BackgroundColor','white');else   set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));endfunction dolyr_Callback(hObject, eventdata, handles)% hObject    handle to dolyr (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% Hints: get(hObject,'String') returns contents of dolyr as text%        str2double(get(hObject,'String')) returns contents of dolyr as a double







⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -