|
[Sponsors] |
Morphology Divergence of a boundary patch field |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
November 6, 2014, 10:27 |
|
#21 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I have found the example of Fam. They are in surfaceTracking file on tutorials. Best regards Fan fei |
||
March 27, 2015, 07:15 |
3D sand slide model
|
#22 |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Hi All:
Recently, I did some work on sand slide model. And I have understood the 2D sand slide model. But, i still confused how to work with 3D sand slide model. someone can give me some hints, any hints are welcome. Best Regards! Fan Fei |
|
March 27, 2015, 08:33 |
|
#23 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hallo Fan Fei,
I have recently had an article accepted, where I describe a 3D geometrical sand sliding routine: http://onlinelibrary.wiley.com/doi/1....4015/abstract Note that this article is also highly relevant with respect to the mass conservation of the sediment due to face-to-vertex interpolation of the rate of bed level change. The native method in OpenFoam (primitivePatchInterpolation with the faceToPoint method) is shown not to be mass conserving. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
April 28, 2015, 09:17 |
|
#24 |
New Member
Lu ZHOU
Join Date: Jul 2014
Location: Lyon, France
Posts: 12
Rep Power: 12 |
Hello Niels,
Sorry to bother you but I am also trying to solve the Exner equation using FAM. I would like to ask is there a difference between directly using the fac::div() function and calculating linearEdgeInterpolate(qB) & aMesh.Le() as you mentioned in your posts ? Also, when I am calculating the divergence on finite area mesh, I've got a problem related to boundary value which I explained here:http://www.cfd-online.com/Forums/ope...area-mesh.html I think it is because I use Qsa.internalField()=vsm.mapToSurface(Qs.boundaryFi eld()) so only the internal field of Qs is mapped but not the boundary values. Is there a function like .correctBoundaryCondition() existed in finite area mesh ? Thank you in advance for any help ! Best regards ! Lu |
|
April 28, 2015, 16:54 |
|
#25 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hallo Lu,
I have never seen that type of problem (with non-periodic domains), and fac::div does obey to a zero gradient. I have very recently used a zero gradient on a bed load field and it worked perfectly. The problem might be related to the mapping, and I have never used the mapping, i.e. I keep all fields on the boundary (in fa-fields). With respect to the difference between fac::div and the dot-product approach, then I would suggest that you look into the article I sighted above, because both the usage of the fac:div approach and the dot-product contains vertical contributions, which even at the continuous level of the Exner equation can lead to instabilities. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 21, 2015, 23:16 |
|
#26 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Hi Niels: I'm so sorry to trouble you. I have study your papar about the mass conservation of interpolated. you did a good job. However, I still have problem understanding the 3D sand slide model. From my unstanding, after the mesh update, the steepest slope of each face are calculated. if the slope exceed the slope of repose, the face cell will need to adjust. And the face will rotated around the face centre for mass conservation, and new location of points of that face will be computed. and then the mesh update, is that right? Greeting ! Fan Fei |
||
May 22, 2015, 02:26 |
|
#27 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hallo Fan Fei,
Thank you. Yes, that is the overall methodology, but you do not need to move the mesh before the sand slide. You could simply use the information from the Exner equation (and prober interpolation) to evaluate the correction due to sand sliding. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 22, 2015, 03:21 |
|
#28 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Thank you for your reply. But I'm more confuse now. Do you mean that as the exner equation solve, the correceted of sand slide should be computed at the same time. In other words, before the points of mesh move, a limiter is constructed to limited the moving of points. is that right? Best regards Fan Fei |
||
May 22, 2015, 03:57 |
|
#29 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Yes, you can consider the sand sliding as a limiter.
(i) Solve the Exner equation, (ii) interpolation to the vertices, (iii) perform sand sliding on the new (but not moved points) and (iv) then update the mesh. Kind regards Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 22, 2015, 06:14 |
|
#30 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Thank you very mech. I'm clear now. However, I have a detials question on perform sand sliding. if i want to limitied the movement of vertices, some variables need: (1)the steepse angle of that face cell (2)the coordinate of face center (3) the coordinate of vertices of that face. Now I have trouble on access the coordinate of vertices of The assigned face. for example i want to get the coordinate of vertices of U.boundaryField()[patchID][i]. is there a function can do that? Thanks. kind regards Fan Fei |
||
May 22, 2015, 11:53 |
|
#31 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Fan Fei,
What you want to achieve is all available through the mesh-connectivity information, e.g. Code:
mesh.faceCells(); mesh.facePoints(); // ... etc Please note that the dualMesh interpolation approach, which I have suggested in my paper, is not available in OpenFoam, so you will need to construct that yourself. With respect to the steepest slope, then it is a simple vectorial derivation, where you merely need the normal vector to the face and the direction of gravity. I will leave it to you to do the derivation. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 22, 2015, 20:38 |
|
#32 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Thank you very much for your reply. I solve Exner and get the movement of face centre with FAM method, then mapped the value to FVM and then interpolated from face centre to vertices with FVM mesh. I test my model with local Scour dut to jet, it can work 5 min. however, when the slope exceed the repose, the critical shields be negative, and the program break down, so i decide to add sand slide model to it. You give me a lot of help for sand slide. Thank you very much. I'll try your method. if it works, i'll be let you know. Thanks. Best regards, Fan Fei |
||
May 23, 2015, 07:28 |
|
#33 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hi Fan Fei,
Yes, you will need a sand sliding module for most problems (especially scour). Your procedure sounds good, but I do not see, why you need to make the mapping between faMesh and fvMesh for the mesh motion. You should be able to perform all of these operations on the faMesh and only communicate directly to the mesh motion solver; through the setting of boundary conditions of the relevant fields, e.g. pointDisplacement, motionU, etc. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 24, 2015, 05:25 |
|
#34 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I used mesh.Cf.boundaryField()[patchID][i] to access coordinate of the face centre of bed, as i access the points of face cell with mesh.facePoints().boundaryField()[patchID][i], some errors are occured. The error show that mesh has no member facePoints(). Is there something wrong with my openfoam version. my openfoam version is openfoam-extend 3.1. Kind regards Fan Fei |
||
May 24, 2015, 09:27 |
|
#35 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I'm so sorry to trouble you. I find a function can access the points of assign face, it's localPoints(), i can use mesh.boundaryMesh[patchID].localPoints to access the the coordinate of points of assign faces. However, when i use for loop to access the assign face cell. some error occured. *********************code************************* ************ for(int ii=0; ii<mesh.boundaryMesh[patchID].size();ii++) int bb=sizeof(mesh.boundaryMesh[patchID][ii].localPoints); ************************************************** ******** the error is Error:'const class Foam::face' has no member named 'localPoints'. How I corrected this error. Thanks Kind regards Fan Fei |
||
May 26, 2015, 00:16 |
|
#36 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I have found a function in face.H file can help me access the points of assign face. **********************code********************** //- Return the points corresponding to this face inline pointField points(const pointField& meshPoints) const; ************************************************* however, when i used mesh.boundaryMesh().[patchWallID].[i].points() to access the points of face[i], an error occured: Error:no matching function for call to "Foam::face:oints() const". I try a lot of methods to correcte it, but I fialed. could you help me to correct this error. Thanks. Best regards Fan Fei |
||
May 26, 2015, 15:01 |
|
#37 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Hallo Fan Fei,
The method requires an input, put you do not pass anything. Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
May 26, 2015, 21:56 |
|
#38 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
Thanks for your kindness. This problem has been solve with labelList and mesh.points() function. As we all know, that a point is shared by several face, as those faces rotated around their centres , this point will get a lot of values, which value should I choose? Kind regards Fan Fei |
||
May 27, 2015, 01:47 |
|
#39 | |
Member
Fei Fan
Join Date: Jul 2013
Location: NanJing, China
Posts: 54
Rep Power: 13 |
Quote:
I think maybe i have misunderstood the sand slide model. Assume that a point shared by for face, and each face will have a value on this point. some of them are positive, some are negative. whether can i chose the maximum negative value and the minimum positive value as the limiter to limited the boundary points move? Best regards Fan fei |
||
May 27, 2015, 03:32 |
|
#40 |
Senior Member
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,903
Rep Power: 37 |
Well, the procedure is to consider one face at the time until you have reached a state, where all faces are less than the sliding angle. Therefore, I do not see any problems in which value to assign to a given point.
Kind regards, Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Given field does not correspond to patch | david | OpenFOAM Bugs | 2 | January 29, 2009 14:24 |
Gamma field on boundary patch | tom | OpenFOAM Post-Processing | 0 | March 23, 2008 07:56 |
Boundary condition vector field gradient from two sides of patch face | quba | OpenFOAM | 0 | December 12, 2007 06:26 |
Projection of field onto patch | tehache | OpenFOAM Running, Solving & CFD | 0 | May 7, 2007 03:24 |
velocity field divergence? | gh | FLUENT | 0 | July 6, 2005 12:10 |