
[Sponsors] 
August 1, 2011, 18:39 
[solved]differentiation in one direction

#1 
Senior Member
Mieszko Młody
Join Date: Mar 2009
Location: POLAND, USA
Posts: 136
Rep Power: 9 
Dear Foamers,
Does anyone of you know what is the best way to dicsretize following problem: we have: f(x,y)  scalar function we need: f_xxxx (fourth order) differentiation but only in one direction. i.e. laplacian(f) = f_xx + f_yy but I need only f_xx (in fact I need f_xxxx) Thanks ZM Last edited by ziemowitzima; August 4, 2011 at 14:16. Reason: solved 

August 2, 2011, 01:55 

#2 
New Member
Fabian
Join Date: Jan 2010
Posts: 27
Rep Power: 8 
You should use a difference quoutient, like you have propably seen for f_x. You can perform the difference quotient "four" times or you can have a look here (they have already done it for you):
http://en.wikipedia.org/wiki/Difference_quotient Probably it should be the best for you to read the whole article, but you can also jump ahead to: http://en.wikipedia.org/wiki/Differe....C5.83th_Order 

August 2, 2011, 11:10 

#3 
Senior Member
Mieszko Młody
Join Date: Mar 2009
Location: POLAND, USA
Posts: 136
Rep Power: 9 
Thanks
This I know. I didn't put it explicit in my question but I need to know how to make it in OpenFOAM. Best 

August 2, 2011, 17:52 

#4 
Senior Member
Mieszko Młody
Join Date: Mar 2009
Location: POLAND, USA
Posts: 136
Rep Power: 9 
so far I found such explicit solution:
volVectorField gradT=fvc::grad(T); // (T_x, T_y) volScalarField Txxxx = gradT.component(0); // T_x gradT = fvc::grad(Txxxx); // (T_xx, T_xy) Txxxx = gradT.component(0); // T_xx gradT = fvc::grad(Txxxx); // (T_xxx, T_xxy) Txxxx = gradT.component(0); // T_xxx gradT = fvc::grad(Txxxx); // (T_xxxx, T_xxxy) Txxxx = gradT.component(0); // T_xxxx Maybe someone have some better idea ? Is it possible to descritize T_xxxx implicitly ? ZM 

August 4, 2011, 12:24 

#5 
Senior Member
Mieszko Młody
Join Date: Mar 2009
Location: POLAND, USA
Posts: 136
Rep Power: 9 
It seems that problem can be solved (after Akidess suggestion ):
"... it sounds like you want anisotropic diffusion  why not just pass a diffusion coefficient tensor to laplacian instead of a scalar?..." from: Modifying the laplacian operator So, x  direction diffusion: DTe1D DTe1D [ 0 2 1 0 0 0 0 ] (3e02 0 0 0 0 0 0 0 0 ); x,y and  directions diffusion: DTe3D DTe3D [ 0 2 1 0 0 0 0 ] (3e02 0 0 0 3e02 0 0 0 3e02 ); for f_xxxx it can be done as follows : suppose we have equation f_xxxx = g(x,y), substitution: h = f_xx so we have two "onedirectional" Poison equations to solve: h_xx = g(x,y) f_xx = h(x,y) in OF: fvm::laplacian(DTe1D, h) == g fvm::laplacian(DTe1D, f) == h 

Tags 
one direction diff 
Thread Tools  
Display Modes  


Similar Threads  
Thread  Thread Starter  Forum  Replies  Last Post 
Flow Direction: normal to boundary!!!  Atit  CFX  1  August 2, 2015 13:42 
Accelerate flow in one direction  JanR  FLUENT  2  January 19, 2011 16:52 
[ICEM] Changing edge direction  la7low  ANSYS Meshing & Geometry  2  June 7, 2010 13:26 
Trimmed cell and embedded refinement mesh conversion issues  michele  OpenFOAM Other Meshers: ICEM, Star, Ansys, Pointwise, GridPro, Ansa, ...  2  July 15, 2005 04:15 
direction of porosity  shin  FLUENT  0  February 23, 2005 17:17 