CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Community Contributions (https://www.cfd-online.com/Forums/openfoam-community-contributions/)
-   -   [swak4Foam] query point value (https://www.cfd-online.com/Forums/openfoam-community-contributions/183147-query-point-value.html)

fritzowski January 28, 2017 11:41

query point value
 
Hi,

I'm searching for a solution to query the value of a single point/node, but I've not been able to find the solution in the docs, I could solve it by selecting all nodes and then remove the unwanted ones with a filter, but this is ugly as hell.

Concrete case: It's an heating element(patch) and it should go on and off depending on the T value of a point.

the correct function/call would be a great help :)

floquation January 30, 2017 03:23

Code:

funcName
{
  type swakExpression;
  valueType set;
  setName onePoint; // This causes a single scalar value to be written
  outputControlMode timeStep;
  outputInterval 1;
  verbose true;
  set {
    type cloud;
    axis x; // ??
    points (
      (0 0 0) // your point(s): (x y z)
    );
    setName onePoint;
  }

  accumulations (
    average
  );

  expression "do something fun";
}

I'm not sure what lib I needed for this specific functionObject, but these are all libs I have active:

Code:

libs
(
        "libsimpleFunctionObjects.so"

        "libsimpleSwakFunctionObjects.so"
        "libswakLagrangianParser.so"
        "libswakFunctionObjects.so"
        "libsimpleLagrangianFunctionObjects.so"
);


fritzowski January 31, 2017 07:36

Thank you,

I'll test it tomorrow.

And I think it is ok now to be paranoid, I'm tracked by particles everywhere :D


All times are GMT -4. The time now is 12:07.