assemble external force vector rather than the residual vector by comsol
Hi all, In a simple linear elastic problem, a FE equation can be written as K*U=F, I would like to know if comsol can assemble and output this "F" vector? In the documentation, it seems that comsol can...
View ArticleHow to call external MATLAB functions from COMSOL?
Hello everyone, I have a problem with calling an external MATLAB function from COMSOL model and I would be grateful for any assistance. When I try to call an external MATLAB function from COMSOL I get...
View ArticleComsol+Matlab on Linux cluster: "No user name and password could be obtained"
A problem I had and its solution, for the record. (Just seeing as nobody reported these error messages yet.) Just tried running Comsol+Matlab on a cluster, using what seemed to work before: $ \comsol...
View ArticleHow to loop simulations in Comsol 4.2a with Matlab
Dear comsolers, here is an example on how to loop simulations. I'll let you decode it. 'Preprocessing' that I did before the loop: 1. Build a model in Comsol (attached). 2. Save As Model M-File...
View ArticleQuestion about nodes arrangement in model solutions with "mpheval" function...
Dear colleagues, I need your adviсe! I work with Solid Mechanics and Pressure acoustic modules. I use LiveLink with Matlab to extract solution data from the Comsol model (v.5.2). I defined a parametric...
View ArticleHow to debug MATLAB function (COMSOL 4)
I am able to declare MATLAB function in comsol. When I run comsol, it gives me error "Incorrect size of returned vector. 596 elements were expected, but the returned matrix was 1 x 1" The error is OK...
View ArticleCAD Import Module Error...
Hi, I have created a CAD model and tried to import it into COMSOL, but I was encountered with this error: ''Feature: Import 1 CAD Import Module functionality is not installed. Note: CAD Import Module...
View ArticleVariable boundary conditions
Hi all, I'm using the API to run my COMSOL model multiple times in a loop in MATLAB with different initial and boundary conditions. I was just wondering if it would be possible to set the initial...
View Article1GB MPH file resulting from importing a 4KB Image via MPHIMAGE2GEOM... Why?!
We are trying to import the attached small image into COMSOL using the mphimage2geom command in Matlab Livelink (relevant piece of code is below for your reference). The resulting mph file is over 1GB...
View ArticleSolidworks import via CAD Import Module
Hi Folks, It seems as though the CAD Import module cannot import Solidworks 2016 files, but LiveLink for SolidWorks can... is that a correct understanding? I am just about to have my SolidWorks...
View Articleproblem about comsol can't plot an external Matlab function that Nested a...
Hi, everyone: I have a problem about using an external matlab function that it nested another matlab function but comsol can't plot it. this is my function:>> function out = rho_x(T)...
View Articlemphinterp - Read data from model fails: Error in meshextend: GC overhead...
Hello, I have encountered an error which I can not explain myself. I am calculating multiple models one after another with Matlab and read out data at specific coordinates. This is part of my...
View ArticleHow to debug MATLAB function (COMSOL 4)
I am able to declare MATLAB function in comsol. When I run comsol, it gives me error "Incorrect size of returned vector. 596 elements were expected, but the returned matrix was 1 x 1" The error is OK...
View ArticleHow to extract the stiffness Matrix for a certain element?
Dear all, Hi. I need to extract the stiffness Matrix for a certain element or node before assembling. The "mphmatrix" command gives me the results for whole geometry (After assembly). I wonder if there...
View ArticleBloch boundary condition in 2D phononic crystal
Hi everyone, I am trying to model a 2D phononic crystal in COMSOL. It is essentially a square with a hole at its center. Does anyone know how to set the Bloch boundary condition for the elastic PDE?...
View ArticleJava errors in Comsol 43 with matlab 2011b
When I use matlab2011b to run M-file generated by comsol43 in Linux system, the following massages appear:"Java exception occurred: java.lang.RuntimeException: Could not start the server. at...
View ArticleLive Link for Matlab Help!
Hello everyone , I have a problem with a live link for matlab probably due to my lack of experience with the software and would like your advice : I made a time-dependent model and I want to analyze...
View ArticleUsing data from Matlab
Dear all Comsol users, To make the question simple, a heat transfer model is set up in 2-D, and every step, I want to calculate the heat source term in Matlab (which will be a 2-D matrix), then send...
View ArticleHow to convert a fig file in matlab to comsol?
Recently, I build a 2D image through a matlab function file. Now I want to analysis it in comsol, but I failed to import it. I don't want to convert it to a dxf file. I have read a lot words about the...
View ArticleSingularity error
Hi, when I use Matlab to run the COMSOL simulation, I am getting the error : Repeated error test failures. May have reached a singularity. But when I directly use COMSOL to run the simulation, it works...
View Article