Running External Function
When running the model containing a MATLAB function feature node, COMSOL Multiphysics
automatically starts a MATLAB process that evaluates the function and returns the value to the COMSOL model.
You do not need to start COMSOL with MATLAB to call a MATLAB function from within the model; starting the COMSOL Desktop is sufficient. The MATLAB process starts automatically to evaluate the function.
On Linux operating systems, specify the MATLAB root directory path
MLROOT
and load the gcc library when starting the COMSOL Desktop:
comsol -mlroot MLROOT -forcegcc
.