CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Main CFD Forum (https://www.cfd-online.com/Forums/main/)
-   -   How to use shape function to get the displacement of area from vertex (https://www.cfd-online.com/Forums/main/245289-how-use-shape-function-get-displacement-area-vertex.html)

miraboreasu September 26, 2022 12:01

How to use shape function to get the displacement of area from vertex
 
Hello,

Sorry for another thread.
There is a triangle in the space, I have the displacement (vector) of each vertex, like

d1: -0.000229128 0.000131475 -0.000706995
d2: -0.000252541 6.02E-05 -0.000662299
d3: -0.000270627 0.000147876 -0.000661116

1. How to calculate the displacement in the normal direction of the whole triangle?
2. Is something called shape function related to this, and how?

aerosayan September 26, 2022 20:32

By displacement, do you mean, you want to move/translate the triangle in the direction of its normal?

If yes, then convert the normal into a unit vector, scale it up by the distance you want to move everything, and apply the translation to each point of the triangle.

https://www.gamedev.net/forums/topic...ector/4734660/

I'm new to FEM, but shape functions are used to approximate a solution in a cell. They're polynomial and denote the variation of a property inside each cell's domain.

I'm not an expert, by any means, so I don't know if they're applicable here.

FMDenaro September 27, 2022 04:31

Shape functions are used to define a functional variation in the triangle (or other figures). If you have a triangle (1,2,3) then you can define a linear polynomial:


f(x,y) = c0+c1*x+c2*y


that can be rearranged in terms of the values in the vertices


f(x,y)=N1(x,y)*f1+N2(x,y)*f2+N3(x,y)*f3


where the Nj are the linear shape functions.


As you can see, you can get both derivatives and integrals by simple analytical integration.

miraboreasu September 28, 2022 10:21

Quote:

Originally Posted by FMDenaro (Post 836551)
Shape functions are used to define a functional variation in the triangle (or other figures). If you have a triangle (1,2,3) then you can define a linear polynomial:


f(x,y) = c0+c1*x+c2*y


that can be rearranged in terms of the values in the vertices


f(x,y)=N1(x,y)*f1+N2(x,y)*f2+N3(x,y)*f3


where the Nj are the linear shape functions.


As you can see, you can get both derivatives and integrals by simple analytical integration.



So here is my vertices displacement,

d1: -0.00023 0.000131 -0.00071
d2: -0.00025 6.02E-05 -0.00066
d3: -0.00027 0.000148 -0.00066

I already have the pressure,p, and area, a, of this area.

is d1 the f1? Sorry I didn't understand.

LuckyTran September 28, 2022 10:39

f1 f2 and f3 are the values of f at the vertices 1, 2, and 3.

When you do FEM, at the very beginning, before you do anything else, you do two things:
1) you create a computational grid
2) you (not me, you!) decide a basis for the shape functions, e.g. piecewise linear

It's very weird to say you are doing FEM and then ask somehow else how to evaluate the integral because you must have defined the integral before you can say you are doing FEM. All we can do is state the general principle. Or you must tell us exactly what is your FEM approach and we can help show some of the mechanical steps.

Work comes from integrating the mechanical pressure over the displacement, the integral being determined by your FEM approach. So how did you define the FEM integral? I hope you see the issue.


Unless.. you are not doing FEM at all but something else entirely...

miraboreasu September 28, 2022 13:04

Quote:

Originally Posted by LuckyTran (Post 836635)
f1 f2 and f3 are the values of f at the vertices 1, 2, and 3.

When you do FEM, at the very beginning, before you do anything else, you do two things:
1) you create a computational grid
2) you (not me, you!) decide a basis for the shape functions, e.g. piecewise linear

It's very weird to say you are doing FEM and then ask somehow else how to evaluate the integral because you must have defined the integral before you can say you are doing FEM. All we can do is state the general principle. Or you must tell us exactly what is your FEM approach and we can help show some of the mechanical steps.

Work comes from integrating the mechanical pressure over the displacement, the integral being determined by your FEM approach. So how did you define the FEM integral? I hope you see the issue.


Unless.. you are not doing FEM at all but something else entirely...


I am post-processing results from a combined finite–discrete element method software. So I don't touch on the detail of the method. This software output the displacement of vertices as
d1: -0.00023 0.000131 -0.00071
d2: -0.00025 6.02E-05 -0.00066
d3: -0.00027 0.000148 -0.00066

I know the pressure I applied to the surface meshed by many triangles. And I can calculate the area of each triangle from the nodal coordinates, but I don't know what to do next.

I want to use pressure*area*displacement, but I don't know what displacement I should use.

Can you give me some advice?


All times are GMT -4. The time now is 21:55.