New Member
Seiji Adachi
Join Date: Mar 2009
Location: Stuttgart, Germany
Posts: 5
Rep Power: 17
|
Hello,
I'd like to create a list of volScalarField. I have made testListField.C but
the compilation results in an error at the line highlighted in red.
What's wrong with this?
Code:
#include "fvCFD.H"
int main(int argc, char *argv[])
{
#include "setRootCase.H"
#include "createTime.H"
#include "createMesh.H"
int N = 10; // size of the list
List<volScalarField> X(N);
Info<< "End\n" << endl;
return(0);
}
Quote:
SOURCE=testListField.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-100 -I/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/finiteVolume/lnInclude -I/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/meshTools/lnInclude -IlnInclude -I. -I/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude -I/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64GccDPOpt/testListField.o
In file included from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/List.H:259:0,
from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/labelList.H:48,
from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/UPstream.H:43,
from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/Pstream.H:42,
from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/parRun.H:35,
from /home/sea/OpenFOAM/OpenFOAM-2.2.0/src/finiteVolume/lnInclude/fvCFD.H:4,
from testListField.C:33:
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/List.C: In constructor ‘Foam::List<T>::List(Foam::label) [with T = Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>, Foam::label = int]’:
testListField.C:42:27: instantiated from here
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/List.C:56:9: error: no matching function for call to ‘Foam::GeometricField<double, Foam::fvPatchField, Foam::volMesh>::GeometricField()’
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/List.C:56:9: note: candidates are:
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:605:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Foam::GeometricField<Type, PatchField, GeoMesh>&, const wordList&, const wordList&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::wordList = Foam::List<Foam::word>]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:605:1: note: candidate expects 4 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:570:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Foam::GeometricField<Type, PatchField, GeoMesh>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:570:1: note: candidate expects 3 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:540:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::word&, const Foam::tmp<Foam::GeometricField<Type, PatchField, GeoMesh> >&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:540:1: note: candidate expects 2 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:507:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::word&, const Foam::GeometricField<Type, PatchField, GeoMesh>&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:507:1: note: candidate expects 2 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:475:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Foam::GeometricField<Type, PatchField, GeoMesh>&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:475:1: note: candidate expects 2 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:444:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::tmp<Foam::GeometricField<Type, PatchField, GeoMesh> >&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:444:1: note: candidate expects 1 argument, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:412:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::GeometricField<Type, PatchField, GeoMesh>&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:412:1: note: candidate expects 1 argument, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:371:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dictionary&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:371:1: note: candidate expects 3 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:331:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:331:1: note: candidate expects 2 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:304:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dimensionSet&, const Foam::Field<TypeR>&, const Foam::PtrList<PatchField<Type> >&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:304:1: note: candidate expects 5 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:274:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dimensioned<Form>&, const wordList&, const wordList&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh, Foam::wordList = Foam::List<Foam::word>]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:274:1: note: candidate expects 5 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:245:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dimensioned<Form>&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:245:1: note: candidate expects 4 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:217:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dimensionSet&, const wordList&, const wordList&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh, Foam::wordList = Foam::List<Foam::word>]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:217:1: note: candidate expects 5 arguments, 0 provided
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:187:1: note: Foam::GeometricField<Type, PatchField, GeoMesh>::GeometricField(const Foam::IOobject&, const Mesh&, const Foam::dimensionSet&, const Foam::word&) [with Type = double, PatchField = Foam::fvPatchField, GeoMesh = Foam::volMesh, Foam::GeometricField<Type, PatchField, GeoMesh>::Mesh = Foam::fvMesh]
/home/sea/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/GeometricField.C:187:1: note: candidate expects 4 arguments, 0 provided
make: *** [Make/linux64GccDPOpt/testListField.o] Error 1
|
|