I am planning to buy a new dedicated computer for running COMSOL Multiphysics. What hardware do you recommend?
Given the wide variety of problems solved by COMSOL Multiphysics®, the rapid pace of software and hardware development, and the variety of hardware options with vastly different price points, there is no single optimal computer choice for all use cases.
The single most important factor is ensuring you have enough physical memory (RAM) to solve the largest models you plan to work with, and that the RAM is installed properly. If you do not have sufficient RAM, there will be a significant slowdown, regardless of other hardware options.
To estimate RAM needs, solve smaller models with similar physics to the larger ones you want to solve. Monitor the memory usage and degrees of freedom (DOF) reported in the Solver Log. Fit the data to a curve of the form A×(DOF)NA \times (\text{DOF})^NA×(DOF)N, where AAA and NNN are fitting coefficients, and use it to predict memory needs for your larger models. The exponent NNN is typically between 1 and 2. When using a multigrid preconditioner with an iterative solver, NNN will be closer to 1, and when using a direct solver, NNN will be closer to 2. The coefficient AAA depends on the sparsity of the problem. For example, a thermal radiation problem, where DOFs are nonlocally coupled, will have a much higher AAA compared to a conductive heat transfer problem, where coupling is local.
Note that memory usage versus DOFs can vary significantly between model types, so you may need to repeat this process for each type of model you plan to solve. Ensure the computer has at least this much RAM. Additionally, having significantly more RAM than needed does not provide an advantage. Use the fastest memory speed supported by the CPU you choose.
Performance is also highly dependent on how the memory is installed. All computers access installed memory via a multi-channel memory bus. If the memory banks are not properly populated, memory speed will decrease. For example, consider a single-CPU computer with four memory channels, each with four open DIMM slots, for a total of 16 open DIMM slots.
Typically, if more than two slots per bank are used, memory speed decreases; in some systems, memory speed decreases if more than one slot per bank is used. Your hardware vendor should provide this information. For example, if you plan to install 16 GB of RAM on the above system, install four 4 GB or two 8 GB DIMMs and ensure all memory banks are utilized. Installing four 4 GB DIMMs leaves the most room for future memory upgrades and maximizes multi-channel memory performance. Do not install DIMMs in a way that leaves some memory channels unused, as this results in significant slowdowns due to underutilized memory channels. The schematic below summarizes this:
There is a complex relationship between performance, CPU type, CPU base frequency, cache memory, number of CPUs, number of cores per CPU, and hardware cost. COMSOL’s code base comprises several different classes of algorithms, each with different scaling characteristics. Thus, some hardware factors weigh more heavily on performance than others, depending on the problem type and size. Providing specific hardware recommendations is therefore challenging. Below are general guidelines:
Different CPU architectures offer different features at varying price points.
The above CPUs are current-generation processors marketed to the professional engineering community. Consumer-market CPUs with similar features may also offer comparable performance at a lower cost.
Higher clock speeds generally result in faster performance across all areas of the software. If all other hardware specifications are equal, the relative performance between two computers will be directly proportional to their clock speeds.
Cache memory is directly embedded in the processor. Larger cache sizes are better. All other factors being equal, a machine with more cache will perform better.
The more processor cores, the more parallel threads can be executed simultaneously (known as multithreading). COMSOL automatically utilizes all available cores, though there is a computational cost for doing so. Using a large number of cores in parallel can even result in slowdowns, especially for relatively small models. Some models may also be dominated by single-threaded performance. In general, six- or eight-core systems are a good all-around choice, though systems with more cores may be better, especially when running multiple models in parallel or using the direct PARDISO solver.
If you plan to solve models with many variations in geometry, mesh, materials, or parameters, you will use the Parametric Sweep feature. For example, sweeping over 10 geometric dimensions, 10 materials, and 10 model parameters requires solving a model 1,000 times. Running this as a single job on one computer will take (at worst) 1,000 times as long.
The solve time for sweeping over many parameters can be reduced by running parallel jobs either on a single computer (using any license type) or on a cluster (using a floating network license).
See also Knowledge Base 1250: Running Parametric Sweeps, Batch Sweeps, and Cluster Sweeps from the Command Line.
Always consider whether you can avoid large sweeps by using the Optimization Module.
For COMSOL Multiphysics versions before 5.4, Linux and macOS operating systems may outperform Windows on processors with many cores.
Solid-state drives (SSDs) improve overall system performance compared to hard drives. Faster drives are always better, but if the system uses the drive for swap space (virtual memory), upgrading RAM is more beneficial than investing in faster drives.
Modern dedicated graphics cards from AMD or NVIDIA are recommended. A list of tested graphics cards is available on the system requirements page. Larger graphics card memory allows for visualizing more complex models. Note that a model requiring significant RAM for solving does not necessarily need a large graphics card and vice versa.
General-purpose computing on GPUs is not currently supported.