|
[Sponsors] |
April 13, 2011, 14:53 |
volVolumeField from volSurfaceField
|
#1 |
New Member
Ivan
Join Date: Sep 2010
Location: Russia , Moscow.
Posts: 14
Rep Power: 16 |
Greetings !
To make a volVolumeField consisting of 3 volScalarField i tried this code? but it doesn't work. Code:
volTensorField gradq = fvc::grad(q); volScalarField qx = gradq.component(vector::X); volScalarField qy = gradq.component(vector::Y); volScalarField qz = gradq.component(vector::Z); diaggradq.internalField() = vectorField(qx,qy,qz) ; The main goal is to make a vector (dq/dx , dq/dy , dq/dz), and I can't think how to do it without extracting diagonal elements from grad(q) tensor. Thanks for helping, best regards. |
|
|
|