CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   About storing 'solve' data and changing data (http://www.cfd-online.com/Forums/openfoam/121629-about-storing-solve-data-changing-data.html)

zxj160 August 1, 2013 11:57

About storing 'solve' data and changing data
 
Dear Foamers,

How does 'solve' store old values? What is the difference between A and B? It seems that Method 'A' does not work.

Method A: --- changing the value of 'C' here-----

solve
(
fvm::ddt(C)
+ fvm::div(phi, C)
- fvm::laplacian(kappaEff, C)
==
SourceC
);

Method B:--- changing the value of 'C' here-----

My best regards,
Jian

akidess August 1, 2013 12:08

All GeometricFields have a member oldTime() with a copy of the data of the previous time instance.

zxj160 August 1, 2013 13:22

Thanks. If I want to change 'C' by assignment after completing 'solve', then whether the GeometricFields of 'C' will be changed corresponding to the assignment.

Thanks,
Jian

akidess August 1, 2013 13:37

What exactly are you trying to achieve? Why do you want to change C, and how?


All times are GMT -4. The time now is 17:00.