My models contain a lot of solution data, and I do not want my file sizes to get too large, it takes a lot of disk space. What can I do to reduce file size? Will this reduce the time it takes to solve the model?
File sizes can become significant when a lot of solution data is generated. This is especially true for time-dependent models, but also models involving parameter and frequency sweeps.
Using probes for time dependent models
For many transient simulations, you may only be interested in average, integral, maximum, or minimum quantities evaluated over some domains, boundaries, edges, or points, or some global quantities. In that case, you can specify just the start time and end time within the Times: field of the Time Dependent study settings meaning that the field solutions will only be saved at the start- and end-times. By default, the Probes that you set up will still be updated and stored at all of the timesteps taken by the solver. This will greatly reduce the amount of data in your model, and can speed up solution time, especially contrasting to a model where data is being written out at many timesteps. Also keep in mind that reducing the number of timesteps stored in output has no effect upon the accuracy of the solution as described in: Knowledge Base 1254: Controlling the Time-Dependent Solver Timesteps
The results of probes can be saved at every timestep taken by the solver.
Using selections to reduce the data saved
If is often the case that you are only interested in the results in a subset of the model. In that case, you can define one or more Selections over domains, boundaries, edges, or points and tell the software to only store data from those selections. This is done via the Values of Dependent Variables > Store fields in output settings within each Study type, as shown in the screenshot below. When using this option, only the data within one mesh element of the selections will be saved.
The store fields in output reduces the amount of data stored.
Removing parts of the computed solutions
Sometimes you have already computed a solution and want to remove some parts of it, possibly for model archival purposes. In this case, you can use the Combine Solutions functionality to remove parts of an existing solution. To do so, add a second, empty, Study to your model, and then add a Combine Solutions feature. Set the solution operation: to Remove solutions and select the Solution from which you want to remove stored data. You can then either explicitly or implicitly remove or save data from the model, as shown in the screenshotS below. You also have the option to Clear source solution which will completely remove the data from the originating study.
The Combine Solutions feature can remove part of the data from existing solutions and store then in another data set. Here, the solution at an explicitly selected set of times is stored.
The Implicit option allows an expression to be used to decide which data to keep, or remove. The source solution can also be cleared.
Reducing the size of the unsolved model
Even a model that does not contain any results at all can get quite large. For resolutions to this, see: Knowledge Base 1238: Reducing the size of your COMSOL Multiphysics file
Browse by CategoryError Messages (63)
Structural Mechanics (3)
Fluid Dynamics (1)
ALE / Parameterized Geometry (1)
Product Information (2)
User Models (1)
COMSOL makes every reasonable effort to verify the information you view on this page. Resources and documents are provided for your information only, and COMSOL makes no explicit or implied claims to their validity. COMSOL does not assume any legal liability for the accuracy of the data disclosed. Any trademarks referenced in this document are the property of their respective owners. Consult your product manuals for complete trademark details.