Rank: 4240 based on 28 downloads (last 30 days) and 1 file submitted
photo

Peter T. S. DeVore

E-mail

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Files Posted by Peter T. S. DeVore
Updated   File Tags Downloads
(last 30 days)
Comments Rating
10 Mar 2014 Screenshot Load HITRAN 2004+ Data Imports HITRAN molecular absorption data as raw and absorbance data. Author: Peter T. S. DeVore spectroscopy, chemistry, physics, aerospace, earth science, spectral lineshape 28 1
Comments and Ratings by Peter T. S. DeVore View all
Updated File Comments Rating
04 Feb 2014 Break X Axis Splits the x-axis into 2 disjoint regions in order to hide an uninteresting portion of a figure. Author: Peter

Would be nice if it could support multiple breaks. I, in particular, need that.

20 Aug 2013 Voigt lineshape spectrum simulation GUI This GUI program simulates Voigt spectral lineshape and absorption from HiTRAN output file. Author: Chong Tao

The code would not run with HiTran 2012 data until I made this fix to SimuLS_Callback(source, eventdata) as follows:

C = textscan(fid, ...
['%2f' '%1f' '%12f' '%10f' '%10f' ...
'%5f' '%5f' '%10f' '%4f' '%8f' ...
'%15c' '%15c' '%15c' '%15c' '%6c' ...
'%12c' '%1c' '%7f' '%7f'], 'delimiter', '' ...
, 'whitespace', '');
fclose(fid); %% returned C is a cell

N = length(C{1}); %% Number of lines/ Cell length
%% define a grid
rangeL= -Dd + min(C{3}); %% spectrum region: First line minus 1 cm-1
rangeH = Dd + max(C{3}); %% Last line position + 1 cm-1
grd=[rangeL:stp:rangeH]; %% define the grid

v = grd;
gD = str2num(get(het2, 'string'));
gL = str2num(get(het3, 'string'));
gV = 0.5346*gL + sqrt(0.2166*gL^2 + gD^2); %% Voigt profile half width
x = gL/gV;
SgmvTot = 0;

for i=1:N %% calculate the line shape for each peak

v0(i) = C{3}(i);
S(i) = C{4}(i);
y = abs(v-v0(i))/gV;
Sgmv0(i) = S(i)/(2*gV*(1.065 + 0.447*x + 0.058*x^2));
Sgmv = Sgmv0(i)*((1-x)*exp(-0.693.*y.^2) + (x./(1+y.^2)) + ...
0.016*(1-x)*x*(exp(-0.0841.*y.^2.25)-1./(1 + 0.021.*y.^2.25)));

SgmvTot = SgmvTot + Sgmv;

end

I would also add in code that lets someone choose the range of lines to select, i.e. let the user choose rangeL and rangeH, then only plot lines within that range. Should be an easy fix.

30 Dec 2012 getUserName Returns the user name or id, as informed by the operating system. Author: Felipe G. Nievinski

Works under Linux and Windows 7. Thanks.

15 Mar 2012 mpgwrite The MPEG converter takes a MATLAB movie matrix and writes the movie to disk as an MPEG file. Author: David Foti

Just got it to work!

Specs:
Windows XP Professional x64 Edition
MATLAB R2007b 64-bit

Steps:
1) Install Visual C++ 2008 Express http://www.microsoft.com/visualstudio/en-us/products/2008-editions/express
- It doesn't come with the x64 bit compilers (thanks cheap-o Microsoft)

2) Install Microsoft SDK 6.1
http://www.microsoft.com/downloads/details.aspx?FamilyId=F26B1AA4-741A-433A-9BE5-FA919850BDBF&displaylang=en
- Make sure that the x64 compilers option is selected _before_ installing.

3) In "mpgwrite/src/Makefile"
change "$(MCC) $(MCFLAGS) " to "-v -DWIN32"

4) Open "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\Visual Studio 2008 x64 Win64 Command Prompt"

5) Navigate to the mpgwrite/src folder

6) Run nmake -f Makefile

7) Move mpgwrite.mexw64 to mpgwrite folder (out of the src folder)

8) Add mpgwrite folder to your MATLAB path

Sources:
* http://www.mathworks.com/support/solutions/en/data/1-6IJJ3L/?solution=1-6IJJ3L
* http://grantnz.blogspot.com/2010/07/compiling-matlab-mpgwrite-with-vs2010.html
* Andrea's post above

23 Aug 2011 export_fig Exports figures nicely to a number of vector & bitmap formats. Author: Oliver Woodford

Be warned, you *will* need to tune image parameters to make your image file consistent with the results from saveas.

Comments and Ratings on Peter T. S. DeVore's Files
Updated File Comment by Comments Rating
10 Mar 2014 Load HITRAN 2004+ Data Imports HITRAN molecular absorption data as raw and absorbance data. Author: Peter T. S. DeVore Ian

For calculating your Voigt function, I highly recommend:

http://www.mathworks.com/matlabcentral/fileexchange/38787-faddeeva-package-complex-error-functions

it is both fast and accurate.

Contact us