mphsave
Save a COMSOL model as a file.
Syntax
mphsave(model)
mphsave(model,filename,...)
mphsave(filename)
mphsave(mtag)
mphsave(mtag,filename,...)
Description
mphsave(model)
saves
model
as a COMSOL MPH-file.
mphsave(model,filename,...)
saves
model
to the file named
filename
.
mphsave(filename)
saves the unique model that is loaded in the COMSOL
server
to the file named
filename
.
mphsave(mtag)
saves the model loaded in the COMSOL
server
with the tag
mtag
.
mphsave(mtag,filename,...)
saves the COMSOL model loaded in the COMSOL server with the tag
mtag
to the file named
filename
.
The function
mphsave
accepts the following property/value pairs:
Table 6-41:
property/value pairs for the mphsave command.
property
value
default
description
component
on
|
off
off
Save M-file using the component syntax
copy
on
|
off
off
Save a copy of the model
description
String
Set or append model description
excludedata
on
|
off
Exclude built, computed, and plotted data
filenameis
fullpath
|
name
|
path
fullpath
Use filename as the selected type
optimize
size
|
speed
Optimize for speed or file size
store
on
|
off
on
Store the filename in most recently used files
title
String
Set model title
thumbnail
fighandle
Set model thumbnail
If the filename is not provided, the model has to be saved previously on disk.
If the filename does not provide a path, the file is saved relatively to the current path in MATLAB
®
.
The model can be saved as an MPH-file, Java file, or M-file. The file extension determines which format that is saved.
Note:
Model created with older version than COMSOL 5.3 cannot be saved using the component syntax.
See also
mphopen
,
mphload
,
mphthumbnail
,
mmsave