gmvOutputSpray.H
Go to the documentation of this file.
1gmvFile << "tracers " << particles.size() << nl;
2for (const passiveParticle& p : particles)
3{
4 gmvFile << p.position().x() << " ";
5}
6gmvFile << nl;
7
8for (const passiveParticle& p : particles)
9{
10 gmvFile << p.position().y() << " ";
11}
12gmvFile << nl;
13
14for (const passiveParticle& p : particles)
15{
16 gmvFile << p.position().z() << " ";
17}
18gmvFile << nl;
19
20forAll(lagrangianScalarNames, i)
21{
22 word name = lagrangianScalarNames[i];
23
24 IOField<scalar> s
25 (
26 IOobject
27 (
28 name,
29 runTime.timeName(),
30 cloud::prefix,
31 mesh,
32 IOobject::MUST_READ,
33 IOobject::NO_WRITE
34 )
35 );
36
37 if (s.size())
38 {
39 gmvFile << name << nl;
40
41 forAll(s, n)
42 {
43 gmvFile << s[n] << token::SPACE;
44 }
45 gmvFile << nl;
46 }
47
48}
49
50gmvFile << "endtrace"<< nl;
label n
volScalarField & p
dynamicFvMesh & mesh
engineTime & runTime
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for INVALID.
Definition: exprTraits.C:59
constexpr char nl
The newline '\n' character (0x0a)
Definition: Ostream.H:53
#define forAll(list, i)
Loop across all elements in list.
Definition: stdFoam.H:333