| IMF - Toolbox |
| Example 6 |
1.6 Interface to the MATLAB Command Window
The interface to the MATLAB Command Window is useful if algorithms and methods must be applied to the data series that are not implemented in the IMF - Toolbox. The next example shows how to do calculations in the MATLAB Command Window. Figure 6.71 shows a bow shock crossing of the spacecraft ISEE 1. Using the right mouse button on the background, choosing ‘Data Management’ and selecting ‘IMF_export_data’, the time series can be exported to the MATLAB Command Window. Figure 6.72 shows the dialogue for changing the default variable names. All entered variable names must be valid MATLAB variable names.
Remark:
The command IMF_export_data also merges the time series in the same way as IMF_write_to_mat..
Now calculations can be performed as follows:

Figure 6.71: ISEE 1 bow shock crossing

Figure 6.72: Dialogue for entering variable names for export of data series
Sequence of MATLAB commands in the Command Window :
» BXT=cos(BX_SC./BT);
» IMF_import_data(UT,BX_SC,BY_SC,BZ_SC,BT,BXT)
Name: add cos(BX/BT)
Name of the Time series: [UT]
Name of the Data Series No. 1 : BX
Unit of the Data Series No. 1 : nT
Source of the Data Series No. 1 : wsp
Name of the Data Series No. 2 : BY
Unit of the Data Series No. 2 : nT
Source of the Data Series No. 2 : wsp
Name of the Data Series No. 3 : BZ
Unit of the Data Series No. 3 : nT
Source of the Data Series No. 3 : wsp
Name of the Data Series No. 4 : BT
Unit of the Data Series No. 4 : nT
Source of the Data Series No. 4 : wsp
Name of the Data Series No. 5 : cos(BX/BT)
Unit of the Data Series No. 5 : 1
Source of the Data Series No. 5 : wsp
Are Your Inputs OK? [Y] y
Now the data series are converted to a ws*.MAT-file. Figure 5.73 shows a plot of all the data of the new ws*.MAT-file.
There is also a shorter possibility to import the data into the IMF – Toolbox again. If the names, units, and the sources can remain the same, the command IMF_import_data can be performed without arguments:
» BX_SC= BX_SC.*cos(27*pi/180);
» BY_SC= BY_SC.*cos(27*pi/180);
» BZ_SC= BZ_SC.*cos(27*pi/180);
» BT= BT.*cos(27*pi/180);
» IMF_import_data

Figure 6.73: Data of the new ws*.MAT-file
[ Previous | Reference Summary | Next ]