Main Content

datcomimport

Bring DATCOM file into MATLAB environment

Description

aero = datcomimport(file) imports aerodynamic data from file into aero. Before reading the United States Air Force Digital DATCOM file, datcomimport initializes values to 99999 when there is not a full set of data for the DATCOM case.

example

aero = datcomimport(file,usenan) replaces data points with NaN or zero where no DATCOM methods exist or where the method is not applicable.

example

aero = datcomimport(file,usenan,verbose) displays the status of the DATCOM file being read in the MATLAB® Command Window.

example

aero = datcomimport(file,usenan,verbose,filetype) imports a DATCOM of a particular USAF Digital DATCOM file type.

example

Examples

collapse all

These examples show how to read digital DATACOM files.

Read 1976 Version of Digital DATCOM File

Read the 1976 version Digital DATCOM output file astdatcom.out.

aero = datcomimport('astdatcom.out')
aero = 1×1 cell array
    {1×1 struct}

Read USAF Digital DATCOM Output File Replacing Data Points with Zeros

Read the 1976 Digital DATCOM output file astdatcom.out using zeros to replace data points where no DATCOM methods exist. Use usenanvar variable to set usenan argument to false.

usenanvar = false;
aero = datcomimport('astdatcom.out',usenanvar)
aero = 1×1 cell array
    {1×1 struct}

Read USAF Digital DATCOM Output File Replacing Data Points with Zeros Specifying Verbose Settings

Read the 1976 Digital DATCOM output file astdatcom.out using zeros to replace data points where no DATCOM methods exist and displaying status information in the Command Window. Use usenanvar variable to set usenan argument to false.

usenanvar = false;
aero = datcomimport('astdatcom.out',usenanvar,1)
Loading file 'astdatcom.out'.
Reading input data from file 'astdatcom.out'.
Reading output data from file 'astdatcom.out'.
aero = 1×1 cell array
    {1×1 struct}

Read USAF Digital DATCOM Output File Replacing Data Points with Zeros and Specifying Verbose Settings and DATCOM File Type

Read the 1976 Digital DATCOM output file astdatcom.out using NaNs to replace data points where no DATCOM methods exist, displaying status information in the Command Window, and specifying the DATCOM output file type. Use usenanvar variable to set usenan argument to true.

usenanvar = true;
aero = datcomimport('astdatcom.out',usenanvar,1,6)
Loading file 'astdatcom.out'.
Reading input data from file 'astdatcom.out'.
Reading output data from file 'astdatcom.out'.
aero = 1×1 cell array
    {1×1 struct}

Input Arguments

collapse all

Digital DATCOM output file name, specified as a character vector or cell array of file names. This file is generated from USAF Digital DATCOM files.

The datcomimport supports only these USAF Digital DATCOM files. You can rename the output files before importing them.

Output File from DATCOMFile Type Versions

for006.dat by all DATCOM versions

1976, 1999, 2007, 2008, 2011, and 2014

for021.dat by DATCOM 2007, DATCOM 2008, DATCOM 2011, and DATCOM 2014

2007, 2008, 2011, and 2014

for042.csv by DATCOM 2008, DATCOM 2011, and DATCOM 2014

2008, 2011, and 2014

Example: for006.dat

Dependencies

The datcomimport function accepts DATCOM files of the type specified by the filetype argument. By default, the file type is 6 ( for006.dat, output by all DATCOM versions).

Data Types: char | string

While importing the DATCOM file, replace data points with NaNs (true) or zeros (false) where no DATCOM methods exist or where methods are not applicable.

Data Types: char | string

Read status of import of DATCOM file, specified as:

  • 0 — No status information.

  • 1 — Display a status information as a progress bar.

  • 2 — Display status information in the MATLAB Command Window.

Data Types: double

DATCOM file type, specified as 6, 21, or 42.

Depending on the file type, the datcomimport function expects the imported DATCOM files to contain the fields listed in the Expected Fields column.

filetypeOutput File from DATCOMFile Type VersionsExpected Fields
6

for006.dat by all DATCOM versions

1976, 1999, 2007, 2008, 2011, and 2014

21

for021.dat by DATCOM 2007, DATCOM 2008, DATCOM 2011, and DATCOM 2014

2007, 2008, 2011, and 2014

42

for042.csv by DATCOM 2008, DATCOM 2011, and DATCOM 2014

2008, 2011, and 2014

Note

If filetype is 21, the function collates the breakpoints and data from all the cases and appends them as the last entry of aero.

Data Types: double

Output Arguments

collapse all

DATCOM structures, returned as a cell array of structures.

Limitations

  • The operational limitations of the 1976 version DATCOM apply to the data contained in AERO. For more information on DATCOM limitations, see References, section 2.4.5.

  • USAF Digital DATCOM data for wing section, horizontal tail section, vertical tail section, and ventral fin section are not read.

More About

collapse all

References

[1] AFFDL-TR-79-3032: The USAF Stability and Control DATCOM, Volume 1, User's Manual

[2] AFRL-VA-WP-TR-1998-3009: MISSILE DATCOM, User's Manual – 1997 FORTRAN 90 Revision

[3] AFRL-RB-WP-TR-2009-3015: MISSILE DATCOM, User's Manual – 2008 Revision

[4] AFRL-RB-WP-TR-2011-3071: MISSILE DATCOM, User's Manual – 2011 Revision

[5] AFRL-RQ-WP-TR-2014-3999: MISSILE DATCOM, Users Manual – 2014 Revision

Version History

Introduced in R2006b