MATLAB

Preparing for 64-Bit Windows

Most Windows 7 transitions include the migration to 64-bit Windows and with it the updating of the IT infrastructure and supporting applications. MathWorks provides the following information to help MATLAB users and administrators make the transition to 64-bit Windows.

Note: References to MATLAB also apply to all products in the MATLAB and Simulink product families.

MATLAB Administrators

MATLAB Users

MATLAB Administrators

What hardware and software do I need to run the 64-bit version of MATLAB?

To run 64-bit applications, you need a 64-bit-capable computer and a 64-bit operating system.

Most PCs produced in the last several years are equipped with a CPU capable of executing 64-bit operating systems and applications. For more information on how to tell if a computer is 64-bit capable, see 32-bit and 64-bit Windows: Frequently Asked Questions from Microsoft.

In addition to a 64-bit-capable processor, you need a 64-bit version of Windows. Windows XP, Windows Vista, and Windows 7 have 64-bit versions.

What versions of 64-bit Windows does MathWorks support?

MathWorks supports the 64-bit versions of Windows XP, Windows Vista, and Windows 7 with current service packs. Refer to the system requirements page for more detailed information.

Do all MathWorks products have a 64-bit version?

Most MathWorks products have a 64-bit version. See Platform/Version Availability for the complete list.

Does the 64-bit version of MATLAB include a C compiler?

No.  Unlike the 32-bit version of MATLAB, which bundles the lcc compiler, the 64-bit version of MATLAB does not include a C compiler.  If you use a MathWorks product or feature that requires a C compiler, you will need to install a compiler separately.  See the 64-bit Windows section of Supported and Compatible Compilers for more information on products that require a compiler, and which compilers are supported. Some of the supported compilers are free.

Can I run the 32-bit version of MATLAB on 64-bit Windows? Why would I want to do this?

Yes.  Beginning with R2010b, the 32-bit version of MATLAB is qualified to run on 64-bit Windows.  Earlier versions of MATLAB have not been qualified in this configuration, but are generally expected to work.  For a discussion of the few known limitations, see Is running 32-bit MATLAB on a 64-bit platform supported? MATLAB execution speed may be slightly slower than when running on a "true" 32-bit Windows system.

Running a 32-bit version of MATLAB on 64-bit Windows can serve as an incremental step towards a full transition to running a 64-bit version of MATLAB on 64-bit Windows. 

MATLAB Users

What are the benefits of running the 64-bit version of MATLAB?

Access to larger amounts of memory is the most immediate benefit to a MATLAB user. A 32-bit application has theoretical access to 232 bytes (4 gigabytes) of addressable memory.  However, Windows claims at least a quarter of this, leaving MATLAB with, at best, 3 gigabytes of addressable memory. A 64-bit application has access to all of the memory installed on the computer, and much more if you consider virtual memory. MATLAB users who work with large data sets or who receive out-of-memory errors are likely to have an improved experience when using the 64-bit version of MATLAB.

Does the 64-bit version of MATLAB offer performance benefits?

The ability to leverage more physical memory is the only significant performance benefit of the 64-bit version of MATLAB. While there are platform-specific differences, the 64-bit and 32-bit versions of MATLAB generally perform comparably as of R2011a. In R2010b and older releases, the 64-bit version can be slower than the 32-bit version.

Will switching to the 64-bit version of MATLAB impact the numeric results of my MATLAB applications?

Possibly.  All MATLAB numeric types in the 32-bit and 64-bit versions of MATLAB are the same size, providing broad consistency between the two. At the lowest level of operation, however, a 32-bit and 64-bit application may use CPU registers of differing widths, which can result in slightly different answers due to round-off effects. This effect can be more pronounced when working with data of type single. The differences are unimportant in many applications, but re-examine any application with a high sensitivity to numerical results when transitioning to the 64-bit version of MATLAB.

How can I determine if I am running a 32-bit or 64-bit version of MATLAB?

In the MATLAB Desktop, select Help > About. The About MATLAB dialog box indicates which version you are running.

For programmatic options, refer to How can I determine if I am running a 32-bit version of MATLAB or a 64-bit version of MATLAB?

How do I get my MEX files to run in the 64-bit version of MATLAB?

MEX source files and anything they call must be recompiled for 64-bit Windows. Since 32-bit and 64-bit MEX-files use different file name extensions (.mexw32 and .mexw64 respectively), it is possible to have both 32-bit and 64-bit MEX binaries in the same folder.

Changes in the MEX API to support large data sets may require some accommodation. See How do I update MEX-files to use the large array handling API for further discussion.

Updating Fortran MEX files for 64-bit versions of MATLAB may require additional work, described in the following resources:

The 64-bit version of MATLAB does not include a host compiler for generating MEX binaries. See the 64-bit Windows section of Supported and Compatible Compilers for a list of supported compilers, including some free compilers.

Are MAT-files compatible between the 32-bit and 64-bit versions of MATLAB?

MAT-files created with 32-bit versions and 64-bit versions of MATLAB are compatible with each other.

Note: With large data sets that use the -7.3 MAT-file format, it is possible for the 64-bit version of MATLAB to produce a MAT-file that is too large for the 32-bit version of MATLAB.

I use other software applications that interoperate with MATLAB.  Do all of these applications need to be 64-bit as well?

While 64-bit Windows can run both 32-bit and 64-bit applications and software components, interoperability between two applications may require that both programs be either 32-bit or 64-bit.

In-process communication between 64-bit versions of MATLAB and other applications and software components requires that the other software also be 64-bit, such as:

  • Calling a MEX binary
  • Using a COM object or Active-X control
  • Loading a library through LOADLIBRARY
  • Connecting Database Toolbox to a database via an ODBC interface

Using external software with a 64-bit version of MATLAB in the following situations does not require a 64-bit version of the external software:

  • Exchanging data through files
  • Invoking another application using the ! or system command
  • Communicating via an out-of-process mechanism such as the MATLAB Engine, Automation (with MATLAB as either a client or server), SOAP, or sockets (TCP/IP)
  • Using .NET assemblies, unless they are built for a specific platform

Are there any other functional differences between the 32-bit and 64-bit versions of MATLAB?

There are a small number of functional differences between the 32-bit and 64-bit versions of MATLAB, mostly involving deprecated features in MATLAB that are not available in the 64-bit version.  The following table summarized the differences.

Product 32-bit version 64-bit version

MATLAB

aviread and aviwrite use the Indeo video codec by default.  Use of newer facilities such as VideoReader and VideoWriter is encouraged

Indeo video codec is not available on many 64-bit systems; specify an alternate codec, or migrate to newer facilities such as VideoReader and VideoWriter

 

DDE support is obsolete, but available

DDE support is not available

 

wavrecord and wavplay are available, but deprecated in favor of audiorecorder and audioplayer

Only audiorecorder and audioplayer are available.

 

-shield command-line option is available

-shield is ignored, since it is not beneficial on a 64-bit system

MATLAB Builder NE

WebFigureControl available

WebFigureControl not available

 

-shield command-line option is available

-shield is ignored, as it is not beneficial on a 64-bit system

Data Acquisition Toolbox

Supports a broad range of CompactDAQ, M-Series, and other legacy devices from National Instruments

Supports CompactDAQ devices from National Instruments

 

Supports  daq.createSession and the legacy ANALOGINPUT and ANALOGOUTPUT device interfaces

Supports daq.createSession interface

Instrument Control Toolbox

Supports a broad range of 32-bit VXIplug&play, IVI-C, IVI-COM, and MATLAB high-level drivers  

Supports 64-bit IVI-C and MATLAB high-level drivers

 

Supports a broad range of GPIB adaptors and National Instruments, Agilent, and Tektronix 32-bit VISA libraries

Supports National Instruments and Agilent GPIB adaptors and 64-bit VISA libraries

Simulink Coder

External mode requires all 32-bit systems

External mode requires all 64-bit systems

DSP System Toolbox

aviread and aviwrite use the Indeo video codec by default.  Use of newer facilities such as VideoReader and VideoWriter is encouraged

Indeo video codec is not available on many 64-bit systems; specify an alternate codec. Use of newer facilities such as VideoReader and VideoWriter is encouraged

R2014a

全新MATLAB界面一览

MATLAB 入门 5:07

MATLAB Student