When you first open or create a new model, the root node (
) is the topmost level of the tree. By default, unnamed files are called
Untitled.mph. The filename changes when the file is saved for the first time, but the root node
Name does not change for this top level node. See
The Root Settings and Properties Windows for details about the settings available when this node is clicked.
The default standard file format with the extension .mph. The files contain binary and text data. The mesh and solution data are stored as binary data, while all other information is stored as plain text.
Only one user can open and edit an MPH-file at the same time. If you try to open an MPH-file that is already open in another user’s COMSOL Desktop, that MPH-file is locked, and you get an option to open the MPH-file in a read-only mode (click Open As Read-Only). That means that you can edit the model but you cannot save it unless you save the MPH-file under another name. When an MPH-file is locked, COMSOL creates a separate lock file with the same filename as the MPH-file plus the extension
.lock, stored in the same directory as the locked MPH-file. If a lock file remains after all COMSOL Desktop sessions have ended (which can happen if the COMSOL Desktop session is ended in a nonstandard way), you can reset the lock when trying to open the file the next time by clicking
Reset Lock and Open.
Editable script files that contain sequences of COMSOL commands as Java code (see the COMSOL Multiphysics Programming Reference Manual for more information about these commands). You can compile these Java files and run them as separate applications. Edit the files in a text editor to add additional commands. For parts of the model that appears under a component (such as the geometry, physics, and mesh), the default format is to include the component level in the Java code. If you want do not want to include the component level, clear the Use component syntax check box on the
Methods page in the
Preferences dialog box.
Model files for VBA are editable script files (VBA-files), similar to the model files for Java, for use with VBA (Visual Basic for Applications) in Microsoft Excel®. A model file for VBA contains a sequence of COMSOL commands as a VBA-file (extension .vba). You can use these files from Excel
® to access settings and data in COMSOL models.