Modify field variable (Pressure)

Please login with a confirmed email address before reporting spam

Hello, I want to modify a pressure value at a specified node and use it as the initial value for the stabilized Convection-Diffusion Equation. I can access the field data in Livelink for MATLAB through: pd = mpheval(model, 'p0', 'dataset', 'dset1');

I changed the pressure value as follows: p0_modi = pd;
p0_modi.d1(1,1) = 3;

Since I want to use the modified p0 ("p0_modi.d1"), I tried to set it again through: model.variable('var17').set('p0', p0_modi.d1);

However, due to the unacceptable data type for the .set function, it doesn't work. How can I use "p0_modi" for the p0 variable?


0 Replies Last Post 2024年8月19日 GMT-4 11:48
COMSOL Moderator

Hello Heejae Jang

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.

Reply

Please read the discussion forum rules before posting.

Please log in to post a reply.

Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.