Forum Message

 

 

We have moved the forum to https://forum.ngsolve.org . This is an archived version of the topics until 05/05/23. All the topics were moved to the new forum and conversations can be continued there. This forum is just kept as legacy to not invalidate old links. If you want to continue a conversation just look for the topic in the new forum.

Notice

The forum is in read only mode.

how do you have multiple boundaries with different conditions.

More
2 years 8 months ago #3928 by place
i am trying to apply different boundary conditions to different boundaries, but the first stops working when i add the second, as thought its getting overwritten.
Code:
# parabolic inflow uin1 = CoefficientFunction((-1.5*4*(0-y)*(.41-y)/(.41*.41),0)) gfu.components[0].Set(uin1, definedon=mesh.Boundaries("inlet1")) uin2 = CoefficientFunction((-1.5*4*(1-y)*(1.41-y)/(.41*.41),0)) gfu.components[0].Set(uin2, definedon=mesh.Boundaries("inlet2"))
More
2 years 8 months ago #3930 by christopher
This behaviour is explained here in the documentation:
docu.ngsolve.org/latest/i-tutorials/unit...domains.html#Pitfall !

In short, you have to set them in one .Set call by using a domain (boundary-) wise coefficientfunction:
Code:
gfu.components[0].Set(mesh.BoundaryCF({ "inlet1" : uin1, "inlet2" : uin2}), definedon=mesh.Boundaries("inlet1|inlet2"))
The following user(s) said Thank You: place
More
2 years 8 months ago #3931 by place
thanks

cut/paste straight in and working.

guessed it was something like that, but didn't find it, i'll check that doc.
More
2 years 7 months ago - 2 years 6 months ago #3980 by place
is there a resource for other boundary NS conditions?

* fixed pressure boundary.
* no perpendicular flow. (symmetry)
* infinite (no returning information cf perfectly matching)

all the examples i see are for velocity, i made a guess as to how to do some of these, but no good.

can you help again?

FYI: i want to add a boundary with the pressure from another boundary, somewhere else, in the same model. to approximate a small 'bleed' pipe without the massive simulation cost.

i guess it could (best) be done by just joining the remote geometries, but then i can only really guess how to do that, or even how that's referred to, so i could search for information.
Last edit: 2 years 6 months ago by place.
Time to create page: 0.139 seconds