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.

Why I can't use 'Solid mechanics' interface and 'Deformed geometry' interface together?

Please login with a confirmed email address before reporting spam

Hi

I'm trying to establish a model that contains both 'Solid mechanics' and 'Deformed geometry' interfaces. However, when I click compute, COMSOL will report an error saying

'Undefined variable. Variable: comp1.solid.vel1.u0yY'.

If I use these two interfaces independently, there will be no problem. I'm wondering if this two interfaces couldn't be used together or because I did something wrong. Could anyone help me with this?

Best Runzi


2 Replies Last Post 9 giu 2022, 12:54 GMT-4
Henrik Sönnerlind COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 2 years ago 9 giu 2022, 10:45 GMT-4

Hi Runzi,

This should work. You have discovered a bug that was corrected in version 6.0, so updating may be a good idea. As a workaround, do the following:

  1. Enable Equation View
  2. Go to the Equation View node under the Prescribed Velocity node
  3. In the Weak Expression section, replace the current expression with :
    -(solid.vel1.vx-root.comp1.solid.vel1.u0xTIME)*test(solid.vel1.u0x)-(solid.vel1.vy-root.comp1.solid.vel1.u0yTIME)*test(solid.vel1.u0y)-(solid.vel1.vz-root.comp1.solid.vel1.u0zTIME)*test(solid.vel1.u0z)

As an alternative, if the displacement caused by the prescribed velocity is trivial, you can use a Prescribed Displacement node instead. You just need to integrate the velocity into a displacement by pen and paper.

(You can see that it is a variable with tag 'vel1' that is causing the problem, which leads to my guess that a Prescribed Velocity node in your model that is the source of the error)

-------------------
Henrik Sönnerlind
COMSOL
Hi Runzi, This should work. You have discovered a bug that was corrected in version 6.0, so updating may be a good idea. As a workaround, do the following: 1. Enable Equation View 2. Go to the *Equation View* node under the *Prescribed Velocity* node 3. In the *Weak Expression* section, replace the current expression with : -(solid.vel1.vx-root.comp1.solid.vel1.u0xTIME)\*test(solid.vel1.u0x)-(solid.vel1.vy-root.comp1.solid.vel1.u0yTIME)\*test(solid.vel1.u0y)-(solid.vel1.vz-root.comp1.solid.vel1.u0zTIME)\*test(solid.vel1.u0z) As an alternative, if the displacement caused by the prescribed velocity is trivial, you can use a *Prescribed Displacement* node instead. You just need to integrate the velocity into a displacement by pen and paper. (You can see that it is a variable with tag 'vel1' that is causing the problem, which leads to my guess that a *Prescribed Velocity* node in your model that is the source of the error)

Please login with a confirmed email address before reporting spam

Posted: 2 years ago 9 giu 2022, 12:54 GMT-4

I see. Thank you for your reply!

I see. Thank you for your 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.