Hi there,
I am trying to find the best way to specify a boundary condition at a specific node in a mesh. I have tried modifying the Boundary Condition block in the solver input file but Elmer Solver claims that the result is trivially 0. Is there a recommended way to do this? Or would you recommend connecting the desired node to a "spring"?
Any thoughts would be fantastic!
Thank you.
Joey Reed
Nodal boundary conditions
-
- Site Admin
- Posts: 4832
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: Nodal boundary conditions
See "Target Coordinates" or "Target Nodes". -Peter
Re: Nodal boundary conditions
Hi Peter,
I have tried setting "Target Nodes", but Elmer reports that the answer is trivially 0. I should add that this is in the context of setting forces on the boundary. Everything works great when I set a nodal
displacement. Perhaps I will try "Target Coordinates". Is there a difference in functionality between the two approaches?
Thanks,
Joey
I have tried setting "Target Nodes", but Elmer reports that the answer is trivially 0. I should add that this is in the context of setting forces on the boundary. Everything works great when I set a nodal
displacement. Perhaps I will try "Target Coordinates". Is there a difference in functionality between the two approaches?
Thanks,
Joey
Re: Nodal boundary conditions
Hi there. I tested Target Nodes the first time today on a model of mine. While Target Nodes assigns the boundary condition to a specified node, Target Coordinates should assign it to the node that happens to be closest to the specified coordinates. In my case Target Nodes was the choice as I prepared the mesh around the node I was thinking to apply the boundary condition on since the very beginning.jreed wrote: Perhaps I will try "Target Coordinates". Is there a difference in functionality between the two approaches?
See here.
-
- Site Admin
- Posts: 4832
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: Nodal boundary conditions
Hi
Nodal BCs can be applied as Dirichlet conditions or point loads but probably not as nodal sources/fluxes.
So imagine the heat equation. For standard boundaries the following keywords are ok:
Dirichlet: Temperature = 1.23
Heat flux: Heat flux = 1.23
Nodal heat source: Temperature load = Real 1.23
Here the heat flux and nodal heat source are quite different creatures since heat flux (W/m^2) is integrated over and gets multiplied by the corresponding area, whereas the load is directly applied to the node as a source term (W). They are the same only when the node represents the area of exactly one.
In parallel runs some additional single nodes are created at the boundaries because there can be orphan nodes on the boundary and we would still like to apply Dirichlet conditions for them. However, we don't want to integrate over them and therefore the most flux BCs skip the single nodes. I think also that for the on-the-fly nodes there is no integration implemented because of the following reason.
Luckily for single nodes the representative area is exactly one so you can as well use the "load" to give the BC. So instead give "Displacement 1 load = Real ...".
-Peter
Nodal BCs can be applied as Dirichlet conditions or point loads but probably not as nodal sources/fluxes.
So imagine the heat equation. For standard boundaries the following keywords are ok:
Dirichlet: Temperature = 1.23
Heat flux: Heat flux = 1.23
Nodal heat source: Temperature load = Real 1.23
Here the heat flux and nodal heat source are quite different creatures since heat flux (W/m^2) is integrated over and gets multiplied by the corresponding area, whereas the load is directly applied to the node as a source term (W). They are the same only when the node represents the area of exactly one.
In parallel runs some additional single nodes are created at the boundaries because there can be orphan nodes on the boundary and we would still like to apply Dirichlet conditions for them. However, we don't want to integrate over them and therefore the most flux BCs skip the single nodes. I think also that for the on-the-fly nodes there is no integration implemented because of the following reason.
Luckily for single nodes the representative area is exactly one so you can as well use the "load" to give the BC. So instead give "Displacement 1 load = Real ...".
-Peter
Re: Nodal boundary conditions
Hi,
Thanks for the very informative response. Part of the issue may be that I am more of a mathematician than a structural engineer. Maybe I should give a bit more background on what my collaborator really thinks
would be high value. He wants to get a hold of the stiffness and mass matrices that Elmer assembles and modify the stiffness matrix with a tunable boundary condition. Essentially you search through the stiffness matrix for the entry corresponding to a particular boundary degree of freedom and substitute this value with a stiffness of your choice. To compute the displacements we could then use a linear/nonlinear solver outside of Elmer. In essence, we would be using Elmer for its efficient assembly. I think this approach is called the "direct stiffness approach". The tunability will occur over multiple degrees of freedom and the results will serve as inputs to a machine learning algorithm.Have you come across anybody wanting to do this sort of thing?
The thing that I really like about Elmer is the power it gives the user. I really like the fact that you can embed your own .F90 routines into a simulation without having to rebuild the entire code base. That's a fantastic feature. As a result, I am pretty convinced that this can be done in Elmer.
Thanks again,
Joey
Thanks for the very informative response. Part of the issue may be that I am more of a mathematician than a structural engineer. Maybe I should give a bit more background on what my collaborator really thinks
would be high value. He wants to get a hold of the stiffness and mass matrices that Elmer assembles and modify the stiffness matrix with a tunable boundary condition. Essentially you search through the stiffness matrix for the entry corresponding to a particular boundary degree of freedom and substitute this value with a stiffness of your choice. To compute the displacements we could then use a linear/nonlinear solver outside of Elmer. In essence, we would be using Elmer for its efficient assembly. I think this approach is called the "direct stiffness approach". The tunability will occur over multiple degrees of freedom and the results will serve as inputs to a machine learning algorithm.Have you come across anybody wanting to do this sort of thing?
The thing that I really like about Elmer is the power it gives the user. I really like the fact that you can embed your own .F90 routines into a simulation without having to rebuild the entire code base. That's a fantastic feature. As a result, I am pretty convinced that this can be done in Elmer.
Thanks again,
Joey
-
- Posts: 1
- Joined: 20 Jul 2023, 21:54
- Antispam: Yes
Re: Nodal boundary conditions
Hi,
I'm trying to set forces to the nodes of the top of a simple cantilever beam rather than on the the boundary surface.
Using the Boundary Conditions below the solver does not converge and states the solution is trivially zero.
Boundary Condition 1
Target Nodes(9) = 5 6 7 8 13 14 15 16 18
Name = "Wall"
Displacement 2 = 0.0
Displacement 3 = 0.0
Displacement 1 = 0.0
End
Boundary Condition 2
Target Nodes(3) = 3 4 11
Name = "Force"
Force 2 = -100
End
However if I switch to Target Boundaries as seen below the solver converges fine.
Boundary Condition 1
Target Nodes(9) = 5 6 7 8 13 14 15 16 18
Name = "Wall"
Displacement 2 = 0.0
Displacement 3 = 0.0
Displacement 1 = 0.0
End
Boundary Condition 2
Target Boundaries(1) = 1
Name = "Force"
Force 2 = -100
End
(Nodes 3, 4 ,and 11 are all on the top of boundary 1)
(Nodes 5 6 7 8 13 14 15 16 18 are all on boundary 2)
I was wondering if I'm missing any keywords in the sif file to apply a force on a node as a boundary condition?
I'm trying to set forces to the nodes of the top of a simple cantilever beam rather than on the the boundary surface.
Using the Boundary Conditions below the solver does not converge and states the solution is trivially zero.
Boundary Condition 1
Target Nodes(9) = 5 6 7 8 13 14 15 16 18
Name = "Wall"
Displacement 2 = 0.0
Displacement 3 = 0.0
Displacement 1 = 0.0
End
Boundary Condition 2
Target Nodes(3) = 3 4 11
Name = "Force"
Force 2 = -100
End
However if I switch to Target Boundaries as seen below the solver converges fine.
Boundary Condition 1
Target Nodes(9) = 5 6 7 8 13 14 15 16 18
Name = "Wall"
Displacement 2 = 0.0
Displacement 3 = 0.0
Displacement 1 = 0.0
End
Boundary Condition 2
Target Boundaries(1) = 1
Name = "Force"
Force 2 = -100
End
(Nodes 3, 4 ,and 11 are all on the top of boundary 1)
(Nodes 5 6 7 8 13 14 15 16 18 are all on boundary 2)
I was wondering if I'm missing any keywords in the sif file to apply a force on a node as a boundary condition?
-
- Posts: 2315
- Joined: 25 Jan 2019, 01:28
- Antispam: Yes
Re: Nodal boundary conditions
I have gotten around this issue by creating a boundary of just nodes. Some solvers you can target nodes, but some it appears doesn't work. However it is possible to create a boundary that is comprised of nodes, then you can do
Boundary Condition 2
Name = "BoundaryCondition 2"
Target Boundaries(1) = 7
Force 2 = -200
End
but Boundary 7 are just nodes
mesh.boundary file
797 7 0 0 101 6057
798 7 0 0 101 6059
799 7 0 0 101 6061
boundary 7 is comprise of nodes 6057, 6059, and 6061
Boundary Condition 2
Name = "BoundaryCondition 2"
Target Boundaries(1) = 7
Force 2 = -200
End
but Boundary 7 are just nodes
mesh.boundary file
797 7 0 0 101 6057
798 7 0 0 101 6059
799 7 0 0 101 6061
boundary 7 is comprise of nodes 6057, 6059, and 6061
-
- Posts: 1
- Joined: 16 Feb 2024, 11:21
- Antispam: Yes
Re: Nodal boundary conditions
Hi,raback wrote: ↑09 Aug 2016, 16:47 Hi
Nodal BCs can be applied as Dirichlet conditions or point loads but probably not as nodal sources/fluxes.
So imagine the heat equation. For standard boundaries the following keywords are ok:
Dirichlet: Temperature = 1.23
Heat flux: Heat flux = 1.23
Nodal heat source: Temperature load = Real 1.23
Here the heat flux and nodal heat source are quite different creatures since heat flux (W/m^2) is integrated over and gets multiplied by the corresponding area, whereas the load is directly applied to the node as a source term (W). They are the same only when the node represents the area of exactly one.
In parallel runs some additional single nodes are created at the boundaries because there can be orphan nodes on the boundary and we would still like to apply Dirichlet conditions for them. However, we don't want to integrate over them and therefore the most flux BCs skip the single nodes. I think also that for the on-the-fly nodes there is no integration implemented because of the following reason.
Luckily for single nodes the representative area is exactly one so you can as well use the "load" to give the BC. So instead give "Displacement 1 load = Real ...".
-Peter
I have a follow-up question regarding calculating the heat flux (W/m^2) from a nodal heat source (W). Is this possible? When using the WhitneyAVHarmonicSolver with impedance boundary conditions, I only get the nodal heat source (W). The Joule heating is =0. Can the nodal heat be converted into a heat flux (W/m^2)? I need to export this field for another simulation on a different mesh. What is the corresponding area of each node? How can I ensure good conservation of the heat source?