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.

If statement in Deformed Geometry

Seyed Mohammad Javid Mahmoudzadeh Akherat

Please login with a confirmed email address before reporting spam

Does anyone happen to know if an "if statement" (conditional statement) can be used in the deformed Geometry for prescribed mesh displacement? Meaning, using the CFD module, the deformed geometry only changes the locations where a certain value of the solution is violated.

For example, for dy in prescribed mesh displacement in Deformed Geometry interface, what would be the correct syntax for to requiring that the geometry only changes if wall shear stress (wss) is less than 0.076 Pascal.

We used: if(wss<=0.076[Pa],DT1), where DT1 is a Bernstein basis function we defined in the global variables. "wss" was also defined in definitions. Seems like we're missing at least one argument in the parentheses. Can COMSOL even make sense of this?

2 Replies Last Post 2016年8月2日 GMT-4 15:54
Gunnar Andersson COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago 2016年8月2日 GMT-4 02:02
We used: if(wss<=0.076[Pa],DT1), where DT1 is a Bernstein basis function we defined in the global variables. "wss" was also defined in definitions. Seems like we're missing at least one argument in the parentheses. Can COMSOL even make sense of this?


The if-operator has the following syntax: if(condition, true_branch, false_branch). You seem to only have supplied the true branch; try if(wss<=0.076[Pa],DT1,0).


[QUOTE]We used: if(wss

Seyed Mohammad Javid Mahmoudzadeh Akherat

Please login with a confirmed email address before reporting spam

Posted: 8 years ago 2016年8月2日 GMT-4 15:54
Thank you for your help!
Thank you for your help!

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.