CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM

Steady-state thermal stress analysis by using solidDisplacementFoam

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   August 30, 2012, 12:29
Default Steady-state thermal stress analysis by using solidDisplacementFoam
  #1
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Hello everybody,

I am using OpenFoam 1.7 for solving thermal stress problem. Now I am solving some simple 2D cases and comparing with analytical solution.


In this case there is a beam of length l and a rectangular cross section whose both ends are clamped as shown as below:

fixedEnd1 I-------------------I finxedEnd2
In this problem, initial temperature of beam is constant. Temperatures T and T is rising and decreasing in the lower and upper surfaces respectively. I am using solidDisplacmentFoam for solving this case. I have following concerns:
1. I am doing this problem for steady-state therefore I have changed ddt schemes as steady state in system/fvScheme. Do I need to make more changed for getting steady state solution in solidDisplacementFoam?
2. Analytical solution for this case is 2.52e+08 at upper surface and -2.52e+08 at lower surface. My simulation results are around 2.25e+08 at upper surface and -2.25e+08 at lower surface. I am not getting accurate simulation results as compared to the analytical values. What do I need to do for getting good simulation results?

I appreciate if someone could help me to solve this problem.

Below is my test case, so that someone more experienced than me with OpenFoam con give a hint.

Best regards and thanks in advance for any reply

sar_gam05

0/D

dimensions [0 1 0 0 0 0 0];

internalField uniform (0 0 0);

boundaryField
{
topSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

bottomSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

fixedEnd1
{
type fixedValue;
value uniform (0 0 0);
}

fixedEnd2
{
type fixedValue;
value uniform (0 0 0);
}

defaultFaces
{
type empty;
}
}



0/T

dimensions [0 0 0 1 0 0 0];

internalField uniform 0;

boundaryField
{
topSurface
{
type fixedValue;
value uniform -100;
}
bottomSurface
{
type fixedValue;
value uniform 100;
}

fixedEnd1
{
type zeroGradient;
}
fixedEnd2
{
type zeroGradient;
}
frontAndBack
{
type empty;
}
}


blockMesh

convertToMeters 1;

vertices
(

(0 0 0)
(30 0 0)
(30 10 0)
(0 10 0)
(0 0 0.1)
(30 0 0.1)
(30 10 0.1)
(0 10 0.1)

);

blocks
(
hex (0 1 2 3 4 5 6 7) (150 100 1) simpleGrading (1.0 1.0 1.0)
);

edges
(
);

patches
(
patch
topSurface
(
(3 7 6 2)
)

patch
bottomSurface
(
(4 0 1 5)
)

patch
fixedEnd1
(
(0 4 7 3)
)

patch
fixedEnd2
(
(1 2 6 5)
)
);

mergePatchPairs
(
);




Sargam05 is offline   Reply With Quote

Old   August 31, 2012, 19:47
Default
  #2
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Hi Sargam,

Quote:
Originally Posted by Sargam05 View Post
[SIZE=2]
1. I am doing this problem for steady-state therefore I have changed ddt schemes as steady state in system/fvScheme. Do I need to make more changed for getting steady state solution in solidDisplacementFoam?
Yes, you need to set d2dt2Scheme to steadyState. But also the case needs to be converged - either by using enough outer correctors OR by using multiple time-steps.

Quote:
Originally Posted by Sargam05 View Post
[SIZE=2]
2. Analytical solution for this case is 2.52e+08 at upper surface and -2.52e+08 at lower surface. My simulation results are around 2.25e+08 at upper surface and -2.25e+08 at lower surface. I am not getting accurate simulation results as compared to the analytical values. What do I need to do for getting good simulation results?
Could you post the log here? Also if you could post the case would help.

Philip
bigphil is offline   Reply With Quote

Old   September 4, 2012, 12:16
Default
  #3
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Sargam,


Yes, you need to set d2dt2Scheme to steadyState. But also the case needs to be converged - either by using enough outer correctors OR by using multiple time-steps.


Could you post the log here? Also if you could post the case would help.

Philip



Hi Philip,

Thanks for the reply. Yes, I have used multiple time steps to get converged solution. I have gotten converged solution for this problem.

Please find my test case, and system files as an attachment. I can not able to attach full log file because it is large in size therefore I am sending you some last iterations in log file that will help to show converged solution.

Please feel free to give suggestions.

Thanks,
Sargam
Attached Files
File Type: gz Thermal stress Test Case.docx.tar.gz (10.8 KB, 16 views)
File Type: gz system.tar.gz (1.4 KB, 13 views)
File Type: gz log.tar.gz (69.9 KB, 4 views)
Sargam05 is offline   Reply With Quote

Old   September 4, 2012, 15:56
Default
  #4
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Hi Sargam,

I notice that your model is only converged to a residual of 1.5e-5.
Normally I would converge my solid models to at least 1e-6. I recommend that you converge the model the a tighter tolerance (1e-6, 1e-7 or maybe even tighter and see if there is an effect).

You could solve the model in one time-step if you change the number of outer correctors in your fvSolution:
stressAnalysis
{
compactNormalStress no;
thermalStress yes;
nCorrectors 100000;
D 1e-06;
T 1e-06;
}

Also changing the linear solver relative tolerance to about 0.1 is normally optimum for solid models, and change the tolerance tighter than your solution tolerance:

D
{
solver GAMG;
tolerance 1e-08;
relTol 0.1;
smoother GaussSeidel;
cacheAgglomeration true;
nCellsInCoarsestLevel 20;
agglomerator faceAreaPair;
mergeLevels 1;
}

Are you using the exact same boundary conditions as the analytical solution? i.e. are top and bottom traction-free and are the left and right fixed in every direction or fixed only in their normal direction with zero-shear.

Philip
bigphil is offline   Reply With Quote

Old   September 4, 2012, 22:25
Default
  #5
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Sargam,

I notice that your model is only converged to a residual of 1.5e-5.
Normally I would converge my solid models to at least 1e-6. I recommend that you converge the model the a tighter tolerance (1e-6, 1e-7 or maybe even tighter and see if there is an effect).

You could solve the model in one time-step if you change the number of outer correctors in your fvSolution:
stressAnalysis
{
compactNormalStress no;
thermalStress yes;
nCorrectors 100000;
D 1e-06;
T 1e-06;
}

Also changing the linear solver relative tolerance to about 0.1 is normally optimum for solid models, and change the tolerance tighter than your solution tolerance:

D
{
solver GAMG;
tolerance 1e-08;
relTol 0.1;
smoother GaussSeidel;
cacheAgglomeration true;
nCellsInCoarsestLevel 20;
agglomerator faceAreaPair;
mergeLevels 1;
}

Are you using the exact same boundary conditions as the analytical solution? i.e. are top and bottom traction-free and are the left and right fixed in every direction or fixed only in their normal direction with zero-shear.

Philip

Hi Philip,

Thanks for the quick reply. I have incorporated changes in fvSolution as you suggested but still my solution is different from analytical solution.

Yes I am using similar boundary conditions as given in the problem. Following are my boundary conditions:

0/D

dimensions [0 1 0 0 0 0 0];

internalField uniform (0 0 0);

boundaryField
{
topSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

bottomSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

fixedEnd1
{
type fixedValue;
value uniform (0 0 0);
}

fixedEnd2
{
type fixedValue;
value uniform (0 0 0);
}

defaultFaces
{
type empty;
}
}


0/T

dimensions [0 0 0 1 0 0 0];

internalField uniform 0;

boundaryField
{
topSurface
{
type fixedValue;
value uniform -100;
}
bottomSurface
{
type fixedValue;
value uniform 100;
}

fixedEnd1
{
type zeroGradient;
}
fixedEnd2
{
type zeroGradient;
}
frontAndBack
{
type empty;
}
}


I am also attaching system and log files of my solution. Do you think that something is wrong in boundary conditions and/or system files. Is this okay to use solidDisplacementFoam solver for steady state because I have not changed equations in solidDisplacementFoam.C file (only changed steady state ddt schemes) ?

Thanks,
Sargam
Attached Files
File Type: gz system.tar.gz (1.4 KB, 4 views)
Sargam05 is offline   Reply With Quote

Old   September 4, 2012, 22:57
Default
  #6
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Quote:
Originally Posted by Sargam05 View Post
Hi Philip,

Thanks for the quick reply. I have incorporated changes in fvSolution as you suggested but still my solution is different from analytical solution.

Yes I am using similar boundary conditions as given in the problem. Following are my boundary conditions:

0/D

dimensions [0 1 0 0 0 0 0];

internalField uniform (0 0 0);

boundaryField
{
topSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

bottomSurface
{
type tractionDisplacement;
traction uniform (0 0 0);
pressure uniform 0;
value uniform (0 0 0);
}

fixedEnd1
{
type fixedValue;
value uniform (0 0 0);
}

fixedEnd2
{
type fixedValue;
value uniform (0 0 0);
}

defaultFaces
{
type empty;
}
}


0/T

dimensions [0 0 0 1 0 0 0];

internalField uniform 0;

boundaryField
{
topSurface
{
type fixedValue;
value uniform -100;
}
bottomSurface
{
type fixedValue;
value uniform 100;
}

fixedEnd1
{
type zeroGradient;
}
fixedEnd2
{
type zeroGradient;
}
frontAndBack
{
type empty;
}
}


I am also attaching system and log files of my solution. Do you think that something is wrong in boundary conditions and/or system files. Is this okay to use solidDisplacementFoam solver for steady state because I have not changed equations in solidDisplacementFoam.C file (only changed steady state ddt schemes) ?

Thanks,
Sargam

Hi Philip,

Sorry I am not able to attach log file, it is larger in size therefore I am sending you some last initial iterations from log file.

Iteration: 49997

GAMG: Solving for T, Initial residual = 7.9969e-09, Final residual = 7.9969e-09, No Iterations 0
GAMG: Solving for Dx, Initial residual = 9.99821e-09, Final residual = 9.99821e-09, No Iterations 0
GAMG: Solving for Dy, Initial residual = 9.99863e-09, Final residual = 9.99863e-09, No Iterations 0
ExecutionTime = 517.38 s ClockTime = 522 s

Iteration: 49998

GAMG: Solving for T, Initial residual = 7.9969e-09, Final residual = 7.9969e-09, No Iterations 0
GAMG: Solving for Dx, Initial residual = 9.99821e-09, Final residual = 9.99821e-09, No Iterations 0
GAMG: Solving for Dy, Initial residual = 9.99863e-09, Final residual = 9.99863e-09, No Iterations 0
ExecutionTime = 517.38 s ClockTime = 522 s

Iteration: 49999

GAMG: Solving for T, Initial residual = 7.9969e-09, Final residual = 7.9969e-09, No Iterations 0
GAMG: Solving for Dx, Initial residual = 9.99821e-09, Final residual = 9.99821e-09, No Iterations 0
GAMG: Solving for Dy, Initial residual = 9.99863e-09, Final residual = 9.99863e-09, No Iterations 0
ExecutionTime = 517.39 s ClockTime = 522 s

Iteration: 50000

GAMG: Solving for T, Initial residual = 7.9969e-09, Final residual = 7.9969e-09, No Iterations 0
GAMG: Solving for Dx, Initial residual = 9.99821e-09, Final residual = 9.99821e-09, No Iterations 0
GAMG: Solving for Dy, Initial residual = 9.99863e-09, Final residual = 9.99863e-09, No Iterations 0
Max sigmaEq = 4.4936e+08
ExecutionTime = 517.46 s ClockTime = 522 s

End
Sargam05 is offline   Reply With Quote

Old   September 5, 2012, 03:35
Default
  #7
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Hi Sargam,

OK from your log, your model is converged. By the way, you can see that the solver is doing zero inner iterations, this is because your linear solver tolerance needs to be tighter than your solution tolerance i.e.:
Code:
    D
    {
      tolerance       1e-10; //- this is the linear solver tolerance and it should be tighter than solution tolerance
   
     }


stressAnalysis
{
    D               1e-09; //- solution tolerance to which model is converged
 
}
But your model is converged anyway so this will just reduce your run time not the results.

Yes, it is fine to use solidDisplacementFoam for steady-state, as setting d2dt2 scheme to steady state sets the inertia term to zero so the linear momentum equation becomes steady state. Also, your fvSchemes look fine.

I have successfully used this solver to model a pipe with internal pressure and temperature and the results were in very close agreement with analytical predictions.

Is your analytical solution for a 3-D bar or 2-D bar? You model is 2-D with front and back being the empty directions. Is it possible to post the analytical solution here or give a link to it? Often I have found that when something doesn't agree with the analytical solution, it may be due to boundary conditions being not exactly the same.

Philip
bigphil is offline   Reply With Quote

Old   September 5, 2012, 12:48
Default
  #8
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Sargam,

OK from your log, your model is converged. By the way, you can see that the solver is doing zero inner iterations, this is because your linear solver tolerance needs to be tighter than your solution tolerance i.e.:
Code:
    D
    {
      tolerance       1e-10; //- this is the linear solver tolerance and it should be tighter than solution tolerance
   
     }


stressAnalysis
{
    D               1e-09; //- solution tolerance to which model is converged
 
}
But your model is converged anyway so this will just reduce your run time not the results.

Yes, it is fine to use solidDisplacementFoam for steady-state, as setting d2dt2 scheme to steady state sets the inertia term to zero so the linear momentum equation becomes steady state. Also, your fvSchemes look fine.

I have successfully used this solver to model a pipe with internal pressure and temperature and the results were in very close agreement with analytical predictions.

Is your analytical solution for a 3-D bar or 2-D bar? You model is 2-D with front and back being the empty directions. Is it possible to post the analytical solution here or give a link to it? Often I have found that when something doesn't agree with the analytical solution, it may be due to boundary conditions being not exactly the same.

Philip

Hi Philip,

Thanks for the reply. I appreciate your valuable inputs. I have taken this problem from a book "Thermal Stresses" by Naotake et al. Please open following link and find this problem in capter-2, Thermal Stresses in Beams, page number 31, heading number 2.1.2.

In this problem I have not considered curvature.

http://books.google.ca/books?id=u3XG...stress&f=false


I am using right boundary conditions or I need to change boundary conditions?

Thanks,
Sargam
Sargam05 is offline   Reply With Quote

Old   September 6, 2012, 04:16
Default
  #9
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Sargam,

Hmmnn I am not sure what boundary conditions are assumed in the analytical solution, it is not clear. The solution says the beam is clamped at the left and right and then says that the beam will remain perfectly straight when the temperatures are applied, but when you apply a temperature to the top and bottom the beam will warp even if the left and right are clamped.

Is there a reason why you are using this particular case? There are many analytical solutions for coupled thermal-stress problems, if you are just interested in verifying the solver.

Best regards,
Philip
bigphil is offline   Reply With Quote

Old   September 6, 2012, 12:33
Default
  #10
Member
 
Sangeeta
Join Date: Jul 2012
Location: Kingston, Canada
Posts: 70
Rep Power: 5
Sargam05 is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Sargam,

Hmmnn I am not sure what boundary conditions are assumed in the analytical solution, it is not clear. The solution says the beam is clamped at the left and right and then says that the beam will remain perfectly straight when the temperatures are applied, but when you apply a temperature to the top and bottom the beam will warp even if the left and right are clamped.

Is there a reason why you are using this particular case? There are many analytical solutions for coupled thermal-stress problems, if you are just interested in verifying the solver.

Best regards,
Philip

Hi Philip,

Thank you for the reply. Actually I am solving this problem just to verify the solver. Could you please suggest me some simple example problems/book/journal so that I can validate analytical results with simulation results?

Thanks in advance.
Sargam
Sargam05 is offline   Reply With Quote

Old   September 6, 2012, 14:22
Default
  #11
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Sargam,

OK, I would recommend a thick walled cylinder with temperature T_i at the inner surface and T_o at the outer surface - described here in the Ansys benchmarks.

The analytical solution can be found in Timoshenko. I can email you the relevant equations if you pm me your email address.

Best regards,
Philip
bigphil is offline   Reply With Quote

Old   September 12, 2012, 10:41
Default
  #12
Senior Member
 
Markus Rehm
Join Date: Mar 2009
Location: Erlangen (Germany)
Posts: 176
Rep Power: 8
markusrehm is on a distinguished road
Hi Philip, hi Sargam,

could one of you provide the Timoshenko-case?

Thanks, Markus.
markusrehm is offline   Reply With Quote

Old   September 12, 2012, 10:51
Default
  #13
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Hi Markus,

Actually the hotCylinder test case is in the recently released solidMechanics solvers for OpenFOAM-1.6-ext (see here).
There is also a utility which outputs the analytical solution.

Best regards,
Philip
bigphil is offline   Reply With Quote

Old   September 12, 2012, 12:37
Default About zero flux boundary condition...
  #14
Member
 
M Mallikarjuna Reddy
Join Date: Jul 2012
Posts: 91
Rep Power: 5
mmkr825 is on a distinguished road
Hi everyone,
I am fresher for openFoam. I have written my own application. I am doing my project on suspension (solid particles in fluid) flow through straight channels. I prepared my solver for the coupling of continuity, momentum and particle conservation equation.
Now i am facing problem with boundary condition for the particle volume fraction at the upper and lower walls. When applied this condition in particle conservation equation i got an expression for the gradient of particle volume fraction.
my governing equation for the particle volume fraction is:-

solve
(
fvm::div(phi, T)
+ fvm::laplacian(0.62*1.82*pow(a,2)*g*pow(T,2)*pow(0 .68-T,-1), T)
+ fvm::laplacian(0.41*pow(a,2)*g*T, T)
==
- fvc::laplacian(0.41*pow(a,2)*T*T, g)
);


where T=particle volume fraction (no units)
where g=local strain rate scalar=1.41421*sqrt(magSqr(symm(fvc::grad(U))))

After applying zero boundary condition i got an expression for gradient as:-
grad(T)= - 0.41*pow(T, 2)*(fvc::grad(g))/(T*g*(0.41+T*1.1284*pow(0.68-T, -1)))

For this purpose i need to develop derived boundary condition. I checked the boundary conditions and found that solidDisplacementFoam/tractionDisplacement matches for my needs. I developed code based upon that solver but i am getting some error message. That's why i reproduced the same tractionDisplacement changing name to mytractionDisplacement.

when i compiled with wmake the following error is coming (which is same as those i obtained for the above gradient expression)
Error message:-
malli_reddy@ubuntu:~/Desktop/mysolidDisplacementFoam/mytractionDisplacement$ wmake

Making dependency list for source file mytractionDisplacementFvPatchVectorField.C
SOURCE=mytractionDisplacementFvPatchVectorField.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam211/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam211/src/OpenFOAM/lnInclude -I/opt/openfoam211/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/mytractionDisplacementFvPatchVectorField.o
g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam211/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam211/src/OpenFOAM/lnInclude -I/opt/openfoam211/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linuxGccDPOpt/mytractionDisplacementFvPatchVectorField.o -L/opt/openfoam211/platforms/linuxGccDPOpt/lib \
-lfiniteVolume -lOpenFOAM -ldl -lm -o /home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/platforms/linuxGccDPOpt
/bin/mytractionDisplacementFvPatchVectorField
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.5.2/../../../crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status
make: *** [/home/malli_reddy/OpenFOAM/
malli_reddy-2.1.1/platforms/linuxGccDPOpt/bin/mytractionDisplacementFvPatchVectorField] Error 1

Please guide me to rectify this error. Now i am using OF 2.1.1 version. And give any valuable information about swak4Foam utility.

Thanks
Regards
Mallikarjuna
mmkr825 is offline   Reply With Quote

Old   September 12, 2012, 13:01
Default
  #15
Senior Member
 
bigphil's Avatar
 
Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 568
Rep Power: 19
bigphil will become famous soon enoughbigphil will become famous soon enough
Quote:
Originally Posted by mmkr825 View Post
Hi everyone,
I am fresher for openFoam. I have written my own application. I am doing my project on suspension (solid particles in fluid) flow through straight channels. I prepared my solver for the coupling of continuity, momentum and particle conservation equation.
Now i am facing problem with boundary condition for the particle volume fraction at the upper and lower walls. When applied this condition in particle conservation equation i got an expression for the gradient of particle volume fraction.
my governing equation for the particle volume fraction is:-

solve
(
fvm::div(phi, T)
+ fvm::laplacian(0.62*1.82*pow(a,2)*g*pow(T,2)*pow(0 .68-T,-1), T)
+ fvm::laplacian(0.41*pow(a,2)*g*T, T)
==
- fvc::laplacian(0.41*pow(a,2)*T*T, g)
);


where T=particle volume fraction (no units)
where g=local strain rate scalar=1.41421*sqrt(magSqr(symm(fvc::grad(U))))

After applying zero boundary condition i got an expression for gradient as:-
grad(T)= - 0.41*pow(T, 2)*(fvc::grad(g))/(T*g*(0.41+T*1.1284*pow(0.68-T, -1)))

For this purpose i need to develop derived boundary condition. I checked the boundary conditions and found that solidDisplacementFoam/tractionDisplacement matches for my needs. I developed code based upon that solver but i am getting some error message. That's why i reproduced the same tractionDisplacement changing name to mytractionDisplacement.

when i compiled with wmake the following error is coming (which is same as those i obtained for the above gradient expression)
Error message:-
malli_reddy@ubuntu:~/Desktop/mysolidDisplacementFoam/mytractionDisplacement$ wmake

Making dependency list for source file mytractionDisplacementFvPatchVectorField.C
SOURCE=mytractionDisplacementFvPatchVectorField.C ; g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam211/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam211/src/OpenFOAM/lnInclude -I/opt/openfoam211/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linuxGccDPOpt/mytractionDisplacementFvPatchVectorField.o
g++ -m32 -Dlinux -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3 -DNoRepository -ftemplate-depth-100 -I/opt/openfoam211/src/finiteVolume/lnInclude -IlnInclude -I. -I/opt/openfoam211/src/OpenFOAM/lnInclude -I/opt/openfoam211/src/OSspecific/POSIX/lnInclude -fPIC -Xlinker --add-needed -Xlinker --no-as-needed Make/linuxGccDPOpt/mytractionDisplacementFvPatchVectorField.o -L/opt/openfoam211/platforms/linuxGccDPOpt/lib \
-lfiniteVolume -lOpenFOAM -ldl -lm -o /home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/platforms/linuxGccDPOpt
/bin/mytractionDisplacementFvPatchVectorField
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.5.2/../../../crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status
make: *** [/home/malli_reddy/OpenFOAM/
malli_reddy-2.1.1/platforms/linuxGccDPOpt/bin/mytractionDisplacementFvPatchVectorField] Error 1

Please guide me to rectify this error. Now i am using OF 2.1.1 version. And give any valuable information about swak4Foam utility.

Thanks
Regards
Mallikarjuna
Mallikarjuna, as your question is unrelated to the current post, you should create a separate post for you question.

Best regards,
Philip
bigphil is offline   Reply With Quote

Old   September 12, 2012, 13:17
Default
  #16
Member
 
M Mallikarjuna Reddy
Join Date: Jul 2012
Posts: 91
Rep Power: 5
mmkr825 is on a distinguished road
Hi Philip,
very much thanks for quick reply. I have one problem related this posts. When i run my case by using my solver the following error message is coming. I am not getting what it is trying to say,

Error message:-

malli_reddy@ubuntu:~/OpenFOAM/malli_reddy-2.1.1/PROJECT/validation$ myDiffusivecFoam
/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.1.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 2.1.1-221db2718bbb
Exec : myDiffusivecFoam
Date : Sep 12 2012
Time : 22:39:06
Host : "ubuntu"
PID : 2089
Case : /home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/PROJECT/validation
nProcs : 1
sigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
allowSystemOperations : Disallowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0

Reading transportProperties

Reading field p

Reading field U

Reading field T

Reading/calculating face flux field phi

No field sources present


SIMPLE: convergence criteria
field p tolerance 1e-05
field U tolerance 1e-05
field T tolerance 1e-05


Starting time loop

Time = 1nl [0 0 -1 0 0 0 0] 0.005626
DILUPBiCG: Solving for Ux, Initial residual = 1, Final residual = 4.7087e-06, No Iterations 5
DILUPBiCG: Solving for Uy, Initial residual = 0, Final residual = 0, No Iterations 0
#0 Foam::error:rintStack(Foam::Ostream&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#1 Foam::sigFpe::sigHandler(int) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#2 Uninterpreted:
#3 Foam:ILUPreconditioner::calcReciprocalD(Foam::Fi eld<double>&, Foam::lduMatrix const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#4 Foam:ILUPreconditioner:ILUPreconditioner(Foam: :lduMatrix::solver const&, Foam::dictionary const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#5 Foam::lduMatrix:reconditioner::addasymMatrixCons tructorToTable<Foam:ILUPreconditioner>::New(Foam ::lduMatrix::solver const&, Foam::dictionary const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#6 Foam::lduMatrix:reconditioner::New(Foam::lduMatr ix::solver const&, Foam::dictionary const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#7 Foam::PBiCG::solve(Foam::Field<double>&, Foam::Field<double> const&, unsigned char) const in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libOpenFOAM.so"
#8 Foam::fvMatrix<double>::solve(Foam::dictionary const&) in "/opt/openfoam211/platforms/linuxGccDPOpt/lib/libfiniteVolume.so"
#9 Foam::fvMatrix<double>::solve() in "/home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/platforms/linuxGccDPOpt/bin/myDiffusivecFoam"
#10
in "/home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/platforms/linuxGccDPOpt/bin/myDiffusivecFoam"
#11 __libc_start_main in "/lib/i386-linux-gnu/libc.so.6"
#12
in "/home/malli_reddy/OpenFOAM/malli_reddy-2.1.1/platforms/linuxGccDPOpt/bin/myDiffusivecFoam"
Floating point exception


please let me know what is the error.
Thanks
Regards
Mallikarjuna
mmkr825 is offline   Reply With Quote

Old   September 13, 2012, 08:04
Default
  #17
Senior Member
 
Markus Rehm
Join Date: Mar 2009
Location: Erlangen (Germany)
Posts: 176
Rep Power: 8
markusrehm is on a distinguished road
Quote:
Originally Posted by bigphil View Post
Hi Markus,

Actually the hotCylinder test case is in the recently released solidMechanics solvers for OpenFOAM-1.6-ext (see here).
There is also a utility which outputs the analytical solution.

Best regards,
Philip

Thanks a lot. I will check it.

Markus
markusrehm is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Other] Creep Analysis for Stress cell usning ANSYS-WORKBANCH.. sidspark12 ANSYS Meshing & Geometry 1 December 26, 2012 05:29
initial temperature in steady state thermal for ansys workbench syafiq CFX 1 May 7, 2012 17:06
Steady State 2 phase problem fivos FLUENT 0 April 27, 2009 16:34
About the difference between steady and unsteady problems Lisa Main CFD Forum 11 July 5, 2000 14:37
Info: Short Course On Thermal Design of Electronic Equipment Arnold Free Main CFD Forum 0 August 10, 1999 10:18


All times are GMT -4. The time now is 14:51.