|
[Sponsors] |
April 10, 2013, 05:04 |
Probes/Sensors in runtime
|
#1 |
New Member
gabi
Join Date: Mar 2013
Location: Spain
Posts: 6
Rep Power: 13 |
Hi all,
My problema is concerned about the sampling of data during the runtime. I'll try to explain myself pretty clear. I can create a sampleDict for my puntual sensors; for example: Code:
sets ( GaugesP { type patchCloud; axis xyz; patches 1(wall5); points ((1 10 15)); maxDistance 100; } ) Code:
probes { tyoe probes; functionObjectLibs ("libsampling.so"); enabled true; outputControl timeStep; outputInterval 1; } fields ( U ); probeLocations ( (1 10 15) ); Code:
sets ( GaugesL { type uniform; axis xyz; start (0.5 0.001 0); end (0.5 0.001 1); nPoints 101; } ); Can anyone help me? Thanks a lot for your time, g. Last edited by gabitinho; April 10, 2013 at 11:14. |
|
April 10, 2013, 10:52 |
|
#2 |
Super Moderator
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29 |
Do you mean something like this?
just add this to your controlDict Code:
functions { probes { functionObjectLibs ( "libutilityFunctionObjects.so" ); type probes; probeLocations ( ( 0 0 0.4265111 ) ( 0 0 0.5284111 ) ( 0 0 0.7316111 ) ); fields ( p T ); } } |
|
April 10, 2013, 11:20 |
|
#3 |
New Member
gabi
Join Date: Mar 2013
Location: Spain
Posts: 6
Rep Power: 13 |
Hi Niklas,
Thanks for your response; I understand that the code that you wrote it is used for "point gauges" (x,y,z coordinates are needed)... ... BUT I need a code to be placed in the controlDict for "line gauges": starts from one point (Xi,Yi,Zi) and ends in another point (Xe,Ye,Ze), like free-surface gauges that are used in laboratory along a line. g. |
|
April 10, 2013, 18:45 |
|
#4 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
April 11, 2013, 03:58 |
|
#5 | |
New Member
gabi
Join Date: Mar 2013
Location: Spain
Posts: 6
Rep Power: 13 |
Quote:
That's why I am trying to add some lines to my controlDict so I can obtain the info from my sensors in the run-time. g. |
||
April 11, 2013, 05:14 |
|
#6 |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
I said FUNCTIONOBJECT. That is executed at runtime
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
|
April 11, 2013, 07:31 |
|
#7 | |
New Member
gabi
Join Date: Mar 2013
Location: Spain
Posts: 6
Rep Power: 13 |
Hi gschaider,
I think that I am not explaining my self clearly enough, sorry for that... Quote:
I want to do it as a FUNCTIONOBJECT (that is executed at runtime), but I do not know to write the proper lines. so, how do I define the start-point and the end-point of the line-segment? I can NOT use Code:
start (0.5 0.001 0); end (0.5 0.001 1); |
||
April 11, 2013, 08:20 |
|
#8 |
Super Moderator
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29 |
Code:
line { type sets; functionObjectLibs ("libsampling.so"); enabled true; outputControl timeStep; outputInterval 1; interpolationScheme cellPoint; setFormat raw; sets ( line1 { type uniform; axis distance; start ( 0 0 0 ); end ( 1 0 0 ); nPoints 10; } ); fields ( p ); } |
|
April 11, 2013, 08:27 |
|
#9 | |
Assistant Moderator
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51 |
Quote:
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request |
||
August 14, 2015, 13:55 |
|
#10 | |
Member
Gautami Erukulla
Join Date: Mar 2009
Posts: 71
Rep Power: 17 |
Quote:
I am trying to use "sets-line" in the controlDict file exactly as you have posted in this thread. I end up getting the following error. /opt/OpenFOAM-2.2.0/bin/tools/RunFunctions: line 42: 18418 Segmentation fault $APP_RUN "$@" > log.$APP_NAME 2>&1 This is how my controlDict file looks: (After maxDeltaT) Code:
functions { //probes //{ // type probes; // functionObjectLibs ("libsampling.so"); // // outputControl outputTime; // probeLocations // ( // ( 1 0 1 ) // ( 1 0 1.5 ) // ); // fields // ( // p // ); // } line { type sets; functionObjectLibs ("libsampling.so"); enabled true; outputControl timeStep; outputInterval 1; interpolationScheme cellPoint; setFormat raw; sets ( line1 { type uniform; axis distance; start ( 0 0 0 ); end ( 0 0 1.5 ); nPoints 10; } ); fields ( U ); } } Kinldy can you please help me on this issue. Kindly can you please let me know how could I use "sets-somePoints-cloud" option in controDict (for runtime data) where the points coordinates are to be read from a data file. Your guidance is highly appreciated.Thank you. Regards, Gautami. Last edited by wyldckat; August 19, 2015 at 17:11. Reason: Added [CODE][/CODE] markers |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
runTime | deji | OpenFOAM | 2 | January 17, 2019 10:14 |
Access UMean at runtime | deji | OpenFOAM Programming & Development | 3 | April 25, 2016 20:20 |
Mapping values from 2D mesh to 3D mesh boundary during runtime | benk | OpenFOAM Programming & Development | 1 | June 13, 2014 03:39 |
runTime out of scope in functionObject | Sune | OpenFOAM Programming & Development | 2 | September 26, 2012 03:11 |
FORTRAN runtime error, Please help | Harendra | Siemens | 3 | August 23, 2005 04:49 |