An array to store scalar value at every time step
Hi
i am new to OpenFOAM i am trying to compile a solver, in which i need to store the the instantaneous calculated variable (scalar) to array for every time step I mean CF_spatial = gsum(V_ecs)/gsum(por) V_ecs and por are time dependent field variables, but CF_spatial is calculated at every time step and is a scalar value and it is not a field variable, i want to create an array where i can store CF_spatial value at every time step, pls help |
Quote:
When you know the size, then why not using C++ arrays (or OpenFoam class List<T>), otherwise you could use vector from the standard library (std::vectory<T>) and then use the push_back() method. |
All times are GMT -4. The time now is 14:26. |