Main Content
Convert Fortran Arrays
Convert array to pass by reference, not by value
Use these functions to convert between MATLAB® and Fortran types.
Fortran Functions
Real
mxCopyReal8ToPtr | REAL*8 values from Fortran array to pointer
array |
mxCopyPtrToReal8 | REAL*8 values from pointer array to Fortran
array |
mxCopyReal4ToPtr | REAL*4 values from Fortran array to pointer
array |
mxCopyPtrToReal4 | REAL*4 values from pointer array to Fortran
array |
Complex
mxCopyComplex16ToPtr | COMPLEX*16 values from Fortran array to pointer
array |
mxCopyPtrToComplex16 | COMPLEX*16 values from pointer array to Fortran
array |
mxCopyComplex8ToPtr | COMPLEX*8 values from Fortran array to pointer
array |
mxCopyPtrToComplex8 | COMPLEX*8 values from pointer array to Fortran
array |
Integer
mxCopyInteger4ToPtr | INTEGER*4 values from Fortran array to pointer
array |
mxCopyPtrToInteger4 | INTEGER*4 values from pointer array to Fortran
array |
mxCopyInteger2ToPtr | INTEGER*2 values from Fortran array to pointer
array |
mxCopyPtrToInteger2 | INTEGER*2 values from pointer array to Fortran
array |
mxCopyInteger1ToPtr | INTEGER*1 values from Fortran array to pointer
array |
mxCopyPtrToInteger1 | INTEGER*1 values from pointer array to Fortran
array |
Character
mxCopyCharacterToPtr | CHARACTER values from Fortran array to pointer array |
mxCopyPtrToCharacter | CHARACTER values from pointer array to Fortran array |
mxGetString | mxChar array to C-style string or Fortran
character array |
Pointer
mxCopyPtrToPtrArray | Pointer values from pointer array to Fortran array |
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
Asia Pacific
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)