Note: This discussion is about an older version of the COMSOL Multiphysics® software. The information provided may be out of date.
Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
COMSOL Weak form modeling using Matlab Command line
Posted Apr 11, 2014, 12:11 a.m. EDT LiveLink for MATLAB, Modeling Tools & Definitions Version 4.4 0 Replies
Please login with a confirmed email address before reporting spam
I'm trying to build and solve a weak form equation generated from virtual work principle in Matlab via ''COMSOL with MATLAB''.
I know how to solve a weak form equation in COMSOL desktop, but my ultimate goal is to write a for-loop in Matlab and at each time step I will modify the weak form and then let COMSOL to solve this weak form equation over a domain, then I go to next step in the for loop. The structure of the algorithm in Matlab is written below.
for i=1:100
--First, build/modify the weak form equation;
--Second, let COMSOL to solve the weak form equation;
--Third, get the solution for the weak form problem from COMSOL to Matlab using Matlab commands;
end
During this process, I will not manually change the model in COMSOL desktop, all the modification is done through Matlab command lines in MATLAB using COMSOL with MATLAB. So I need to build and modify the weak form equation in MATLAB. Does anyone know how this can be done? Better if you can provide the command lines to build a weak form equation.
Thanks a lot.
Hello Jiacheng Wu
Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.
If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.