📄 kalman_gui.m
字号:
% hObject handle to y_amp (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 y_amp as text% str2double(get(hObject,'String')) returns contents of y_amp as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function y_period_CreateFcn(hObject, eventdata, handles)% hObject handle to y_period (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 y_period_Callback(hObject, eventdata, handles)% hObject handle to y_period (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 y_period as text% str2double(get(hObject,'String')) returns contents of y_period as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function z_amp_CreateFcn(hObject, eventdata, handles)% hObject handle to z_amp (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 z_amp_Callback(hObject, eventdata, handles)% hObject handle to z_amp (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 z_amp as text% str2double(get(hObject,'String')) returns contents of z_amp as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function z_period_CreateFcn(hObject, eventdata, handles)% hObject handle to z_period (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 z_period_Callback(hObject, eventdata, handles)% hObject handle to z_period (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 z_period as text% str2double(get(hObject,'String')) returns contents of z_period as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.
function sampletime_CreateFcn(hObject, eventdata, handles)
% hObject handle to sampletime (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 sampletime_Callback(hObject, eventdata, handles)
% hObject handle to sampletime (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 sampletime as text
% str2double(get(hObject,'String')) returns contents of sampletime as a double
temp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.
function deltat_CreateFcn(hObject, eventdata, handles)
% hObject handle to deltat (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 deltat_Callback(hObject, eventdata, handles)
% hObject handle to deltat (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 deltat as text
% str2double(get(hObject,'String')) returns contents of deltat as a double
temp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function sigmaaz_CreateFcn(hObject, eventdata, handles)% hObject handle to sigmaaz (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 sigmaaz_Callback(hObject, eventdata, handles)% hObject handle to sigmaaz (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 sigmaaz as text% str2double(get(hObject,'String')) returns contents of sigmaaz as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function sigmael_CreateFcn(hObject, eventdata, handles)% hObject handle to sigmael (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 sigmael_Callback(hObject, eventdata, handles)% hObject handle to sigmael (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 sigmael as text% str2double(get(hObject,'String')) returns contents of sigmael as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.function sigmarange_CreateFcn(hObject, eventdata, handles)% hObject handle to sigmarange (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 sigmarange_Callback(hObject, eventdata, handles)% hObject handle to sigmarange (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 sigmarange as text% str2double(get(hObject,'String')) returns contents of sigmarange as a doubletemp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.
function x0_1_CreateFcn(hObject, eventdata, handles)
% hObject handle to x0_1 (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 x0_1_Callback(hObject, eventdata, handles)
% hObject handle to x0_1 (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 x0_1 as text
% str2double(get(hObject,'String')) returns contents of x0_1 as a double
temp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.
function x0_2_CreateFcn(hObject, eventdata, handles)
% hObject handle to x0_2 (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 x0_2_Callback(hObject, eventdata, handles)
% hObject handle to x0_2 (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 x0_2 as text
% str2double(get(hObject,'String')) returns contents of x0_2 as a double
temp = str2double(get(hObject, 'String'));
if isnan(temp)
set(hObject, 'String', 0);
errordlg('Input must be a number','Error');
end
% --- Executes during object creation, after setting all properties.
function x0_3_CreateFcn(hObject, eventdata, handles)
% hObject handle to x0_3 (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 x0_3_Callback(hObject, eventdata, handles)
% hObject handle to x0_3 (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 x0_3 as text
% str2double(get(hObject,'String')) returns contents of x0_3 as a double
temp = str2double(get(hObject, 'String'));
if isnan(temp)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -