2 // Volume surfactant concentration
4 volScalarField* CPtr = NULL;
6 if(!interface.cleanInterface() && interface.surfactant().soluble())
8 Info << "\nReading field C\n" << endl;
9 CPtr = new volScalarField
22 if(runTime.timeIndex() == 0)
24 const dimensionedScalar& CA =
25 interface.surfactant().surfactBulkConc();
27 dimensionedScalar CB("CB", CA.dimensions(), 0);
29 (*CPtr) = fluidIndicator*(CA - CB) + CB;
33 CPtr->boundaryField()[spacePatchID].type()
34 == inletOutletFvPatchScalarField::typeName
37 inletOutletFvPatchScalarField& spaceC =
38 refCast<inletOutletFvPatchScalarField>
40 CPtr->boundaryField()[spacePatchID]
43 spaceC.refValue() = CA.value();
47 FatalErrorIn(args.executable())
48 << "Boundary condition for bulk surfactant concentration at "
49 << "space patch isn't and should be: "
50 << inletOutletFvPatchScalarField::typeName
54 CPtr->correctBoundaryConditions();