Code covered by the BSD License  

Highlights from
Weeks' Method for Numerical Laplace transform inversion with GPU acceleration

image thumbnail
from Weeks' Method for Numerical Laplace transform inversion with GPU acceleration by Patrick Kano
Implementation of the Weeks method for numerical Laplace transform inversion with GPU acceleration.

acunumweeks(varargin)
function varargout = acunumweeks(varargin)
% ACUNUMWEEKS MATLAB code for acunumweeks.fig
%      ACUNUMWEEKS, by itself, creates a new ACUNUMWEEKS or raises the existing
%      singleton*.
%
%      H = ACUNUMWEEKS returns the handle to a new ACUNUMWEEKS or the handle to
%      the existing singleton*.
%
%      ACUNUMWEEKS('CALLBACK',hObject,eventData,handles,...) calls the local
%      function named CALLBACK in ACUNUMWEEKS.M with the given input arguments.
%
%      ACUNUMWEEKS('Property','Value',...) creates a new ACUNUMWEEKS or raises the
%      existing singleton*.  Starting from the left, property value pairs are
%      applied to the GUI before acunumweeks_OpeningFcn gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to acunumweeks_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 acunumweeks

% Last Modified by GUIDE v2.5 27-Oct-2011 21:33:54

% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @acunumweeks_OpeningFcn, ...
                   'gui_OutputFcn',  @acunumweeks_OutputFcn, ...
                   'gui_LayoutFcn',  [] , ...
                   'gui_Callback',   []);
if nargin && ischar(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 acunumweeks is made visible.
function acunumweeks_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 acunumweeks (see VARARGIN)

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

% Update handles structure
guidata(hObject, handles);

% UIWAIT makes acunumweeks wait for user response (see UIRESUME)
% uiwait(handles.tag_main_figure);

%P. Kano format display
format long g;
format compact;

%Oct. 25, 2011 - Add subdirectory only on startup of the GUI
addpath('WEEKS_METHOD');

%Check for JACKET on startup
JacketFlag = wfnCheckGPUsoft();
if(JacketFlag==0)
 warndlg('JACKET not detected on the MATLAB path.',[mfilename,':JACKET']);
 warning([mfilename,':JACKET'],'JACKET not detected on the MATLAB path.');
end

%Oct. 13, 2011 - Add Acunum GUI logo
acunumlogo = imread('acunumlogo.jpg');
axes(handles.tag_axes_logo);
%set(handles.tag_axes_logo,'XTick',[]);
%set(handles.tag_axes_logo,'YTick',[]);
image(acunumlogo);
axis off;

% --- Outputs from this function are returned to the command line.
function varargout = acunumweeks_OutputFcn(hObject, eventdata, handles) 
% varargout  cell array 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;



function tag_edit_FS_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_FS (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 tag_edit_FS as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_FS as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_FS_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_FS (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

function tag_edit_inversetime_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_inversetime (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 tag_edit_inversetime as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_inversetime as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_inversetime_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_inversetime (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

function tag_edit_exactft_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_exactft (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 tag_edit_exactft as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_exactft as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_exactft_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_exactft (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end


%handles.tag_axes_logo --- Executes on button press in tag_check_showfterror.
function tag_check_showfterror_Callback(hObject, eventdata, handles)
% hObject    handle to tag_check_showfterror (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of tag_check_showfterror
tempcheck = get(handles.tag_check_showfterror,'value');
if tempcheck==0 %off
 cla(handles.tag_axes_fterror);
 legend off;
 set(handles.tag_axes_fterror,'visible','off');
else
 set(handles.tag_axes_fterror,'visible','on');   
end

% --- Executes on button press in tag_check_compare.
function tag_check_compare_Callback(hObject, eventdata, handles)  
% hObject    handle to tag_check_compare (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of tag_check_compare
tempcheck = get(handles.tag_check_compare,'Value');
if tempcheck==0 %off
 set(handles.tag_text_exactft,'visible','off');
 set(handles.tag_edit_exactft,'visible','off');
else %on
 set(handles.tag_text_exactft,'visible','on');
 set(handles.tag_edit_exactft,'visible','on');
end


% --- Executes on button press in tag_check_properties.
function tag_check_properties_Callback(hObject, eventdata, handles)
% hObject    handle to tag_check_properties (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hint: get(hObject,'Value') returns toggle state of tag_check_properties
tempcheck = get(handles.tag_check_properties,'Value');
if tempcheck==0 %off
    
 set(handles.tag_pop_searchdomain,'Value',1);

 set(handles.tag_pop_searchmethod,'Value',1);  
    
 set(handles.tag_text_searchm,'visible','off');
 set(handles.tag_pop_searchmethod,'visible','off');

 set(handles.tag_text_searchdomain,'visible','off');
 set(handles.tag_pop_searchdomain,'visible','off'); 
 
 set(handles.tag_panel_computer_defined,'visible','off');
 set(handles.tag_panel_userselprop,'visible','off');
else %on
 set(handles.tag_text_searchm,'visible','on');
 set(handles.tag_pop_searchmethod,'visible','on');

 set(handles.tag_text_searchdomain,'visible','on');
 set(handles.tag_pop_searchdomain,'visible','on'); 
end


% --- Executes on selection change in tag_pop_searchmethod.
function tag_pop_searchdomain_Callback(hObject, eventdata, handles)
% hObject    handle to tag_pop_searchdomain (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: contents = cellstr(get(hObject,'String')) returns tag_pop_searchdomain contents as cell array
%        contents{get(hObject,'Value')} returns selected item from tag_pop_searchdomain

DomainSwitch = get(hObject,'Value');
%1-wrapped/auto, 2-user defined parameters/maunaul
if DomainSwitch==1
 set(handles.tag_panel_computer_defined,'visible','on');
 set(handles.tag_panel_userselprop,'visible','off');
else
 set(handles.tag_panel_computer_defined,'visible','off');
 set(handles.tag_panel_userselprop,'visible','on');
end 

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

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

% --- Executes on selection change in tag_pop_searchmethod.
function tag_pop_searchmethod_Callback(hObject, eventdata, handles)
% hObject    handle to tag_pop_searchmethod (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: contents = cellstr(get(hObject,'String')) returns tag_pop_searchmethod contents as cell array
%        contents{get(hObject,'Value')} returns selected item from tag_pop_searchmethod


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

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


% --- Executes on slider movement.
function tag_slider_tol_Callback(hObject, eventdata, handles)
% hObject    handle to tag_slider_tol (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,'Value') returns position of slider
%        get(hObject,'Min') and get(hObject,'Max') to determine range of slider
%set the value of the associated text box
slideval = num2str(get(handles.tag_slider_tol,'Value'));
set(handles.tag_text_slidervalue,'String',slideval);

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

% Hint: slider controls usually have a light gray background.
if isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor',[.9 .9 .9]);
end


% --- Executes on button press in tag_push_invert.
function tag_push_invert_Callback(hObject, eventdata, handles)
% hObject    handle to tag_push_invert (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)


Timevec = str2num(get(handles.tag_edit_inversetime,'String')); %#ok<*ST2NM>

Fs = get(handles.tag_edit_FS,'String');

DomainSwitch = get(handles.tag_pop_searchdomain,'Value');
%1-wrapped/auto, 2-user defined parameters/manual

SearchSwitch = get(handles.tag_pop_searchmethod,'Value');
SearchSwitch = SearchSwitch-1; %subtract 1 to remain consistent with Weeks code
%0) CPU Local Search
%1) GPU Global Search
%2) CPU Local Search

%Note: Default is set in the GUI as
%DomainSwitch==1 -> wrapped/auto
%SearchSwitch==0 -> CPU Local Search

%% WEEKS METHOD COMPUTATIONS
if DomainSwitch==1 %wrapped-computer defined
  
 RelErrorTol = ones(size(Timevec))*get(handles.tag_slider_tol,'Value');
 %Note that code allows RelErrorTol to be diferent for each time.  Here, 
 %in the GUI, they are set to be the same for all inversion times.
 
 switch SearchSwitch
  case 0
   disp('Wrapped Weeks Method: Central Processor [CPU] Local Search');
  case 1
   disp('Wrapped Weeks Method: Central Processor [CPU] Global Search');
  otherwise
   disp('Wrapped Weeks Method: Graphics Processor [GPU] Global Search');
 end
      
 tic;
 [ftapproxval,sigmaP,bP,EstRelError,EstAbsError,~,~,ToleranceFlag] =...
 WeeksMethod(Fs,Timevec,RelErrorTol,SearchSwitch) %#ok displaying is OK
 Runtime = toc;
 
else %Domain Switch==2, user defined
   
 NLag = str2double(get(handles.tag_edit_manual_NLag,'String'));
 sigmamin = str2double(get(handles.tag_edit_manual_sigmamin,'String'));
 sigmamax = str2double(get(handles.tag_edit_manual_sigmamax,'String'));
 bmax = str2double(get(handles.tag_edit_manual_bmax,'String'));
 tols = str2double(get(handles.tag_edit_manual_sigmadelta,'String'));
 tolb = str2double(get(handles.tag_edit_manual_bdelta,'String'));

 switch SearchSwitch
  case 0
   disp('Core Weeks Method: Central Processor [CPU] Local Search');
  case 1
   disp('Core Weeks Method: Central Processor [CPU] Global Search');
  otherwise
   disp('Core Weeks Method: Graphics Processor [GPU] Global Search');
 end
      
 for tidx=1:length(Timevec)
  tic;
  [ftapproxval(tidx),sigmaP(tidx),bP(tidx)] =...
  wfnWeeksCore(Fs,Timevec(tidx),NLag,sigmamin,sigmamax,bmax,SearchSwitch,tols,tolb);
  
  EstAbsError(tidx) = NaN;
  EstRelError(tidx) = NaN;
  ToleranceFlag(tidx) = NaN;
  Runtime(tidx) = toc;
 end %tidx
 
end %Domain Switch

%% PLOT RESULTS
axes(handles.tag_axes_ftplot);
cla;
set(gca,'FontSize',6);
axis off;
plot(Timevec,real(ftapproxval),'-bo'); %small imaginary parts remain
legendstrft = 'approximate';
 
%% COMPARE TO KNOWN f(t)
CompareSwitch = get(handles.tag_check_compare,'Value');
if CompareSwitch==1
 ftexactstr = get(handles.tag_edit_exactft,'String');
 ftexactval = feval(inline(ftexactstr,'t'),Timevec);
 hold on;
 plot(Timevec,ftexactval,'--k+');
 hold off;
 legendstrft = {legendstrft, 'exact'};
 
 MeaAbsError = 100*abs(ftexactval-ftapproxval);  %percent
 MeaRelError = MeaAbsError./abs(ftexactval); %percent
end

xlabel('time');
%ylabel('f(t)');
legend(legendstrft);
axis tight;

%% DISPLAY TEXT TO AXES
ErrDispSwitch = get(handles.tag_check_showfterror,'Value');

if ErrDispSwitch==1
 axes(handles.tag_axes_fterror);
 cla;
 set(gca,'FontSize',6);
 legend('off');
 %hold on;
 
 %MeaRelError already a percentage
 if CompareSwitch==1 && DomainSwitch==1
  semilogy(Timevec,MeaRelError,'--k+',Timevec,(EstRelError*100),'-bo');
  legend('measured','estimated');
  
 elseif CompareSwitch==0 && DomainSwitch==1
  semilogy(Timevec,(EstRelError*100),'-bo');
  legend('estimated');  
     
  %no measured error   
 elseif CompareSwitch==1 && DomainSwitch==2
  semilogy(Timevec,MeaRelError,'--k+'); 
  legend('measured');
  
  axis tight;
  Tempxlim = xlim;
  xdelta = abs(Tempxlim(2)-Tempxlim(1));
 
  Tempylim = ylim;
  ydelta = abs(Tempylim(2)-Tempylim(1));   
  
  xtexpos = Tempxlim(1) + 0.25*xdelta;
  ytexpos = Tempylim(1) + 0.25*ydelta;
  text(xtexpos,log10(ytexpos),'No error estimate computed.');
 else %02
     
  %measured   
  Tempxlim = xlim;
  xdelta = abs(Tempxlim(2)-Tempxlim(1));
 
  Tempylim = ylim;
  ydelta = abs(Tempylim(2)-Tempylim(1));   
  
  xtexpos = Tempxlim(1) + 0.25*xdelta;
  ytexpos = Tempylim(1) + 0.25*ydelta;

  text(xtexpos,ytexpos,'No error estimate computed.');
 end
 
 xlabel('time');
 %ylabel('relative error (%)');
 axis tight;
 %hold off;
 
 %Correct but not included
 %labstr{1} = 'Time: ';
 %valstr{1} = num2str(Timevec);
 %yposvec(1) = 0.8*ydelta;

 %labstr{2} = 'Approximate: ';
 %valstr{2} = num2str(real(ftapproxval));
 %yposvec(2) = 0.6*ydelta;

 %if CompareSwitch==1
 % labstr{3} = 'Exact: ';
 % valstr{3} = num2str(ftexactval);
 % yposvec(3) = 0.4*ydelta;
 
 % labstr{4} = 'Absolute Error %: ';
 % valstr{4} = num2str(MeaAbsError);
 % yposvec(4) = 0.2*ydelta;

 %xposvec = 0.01*ones(size(yposvec));
 %text(xposvec,yposvec,labstr,'fontsize',8);
 %text(xposvec,yposvec-0.1*ydelta,valstr,'fontsize',8);
end %error figure

%% DIPLAY IN THE WORK ENVIRONMENT
disp('Time: '); disp(Timevec);
disp('Approximate: '); disp(real(ftapproxval));
if CompareSwitch==1
 disp('Exact: '); disp(ftexactval); 
 disp('Measured Absolute Error %: '); disp(MeaAbsError);
end
disp('Estimated Absolute Error %: '); disp(EstAbsError*100);
if CompareSwitch==1
 disp('Measured Relative Error %: '); disp(MeaRelError);
end
disp('Estimated Relative Error %: '); disp(EstRelError*100);
disp('Run Time :'); disp(Runtime');
disp('sigma: '); disp(sigmaP);
disp('b:');  disp(bP);
disp('Tolerance Flag: '); disp(ToleranceFlag);


function tag_edit_manual_NLag_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_NLag (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 tag_edit_manual_NLag as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_NLag as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_NLag_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_NLag (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_sigmamin_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmamin (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 tag_edit_manual_sigmamin as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_sigmamin as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_sigmamin_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmamin (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_sigmamax_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmamax (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 tag_edit_manual_sigmamax as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_sigmamax as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_sigmamax_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmamax (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_sigmadelta_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmadelta (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 tag_edit_manual_sigmadelta as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_sigmadelta as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_sigmadelta_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_sigmadelta (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_bmin_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bmin (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 tag_edit_manual_bmin as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_bmin as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_bmin_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bmin (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_bmax_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bmax (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 tag_edit_manual_bmax as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_bmax as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_bmax_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bmax (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end



function tag_edit_manual_bdelta_Callback(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bdelta (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 tag_edit_manual_bdelta as text
%        str2double(get(hObject,'String')) returns contents of tag_edit_manual_bdelta as a double


% --- Executes during object creation, after setting all properties.
function tag_edit_manual_bdelta_CreateFcn(hObject, eventdata, handles)
% hObject    handle to tag_edit_manual_bdelta (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 && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
    set(hObject,'BackgroundColor','white');
end

Contact us