CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Pre-Processing

Mapping values to inlet (from samples) with different # of points at each time step

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 26, 2016, 07:16
Question Mapping values to inlet (from samples) with different # of points at each time step
  #1
Member
 
Join Date: Feb 2015
Posts: 39
Rep Power: 11
HenningW is on a distinguished road
Hi everyone,

I have a case with moving airfoils to influence the flow. Since I am not actually interested in the moving airfoils but in their wake, I simulated the moving airfoils and probed the wake with a surface. My plan is to use the results as an input for future simulations at the inlet so I do not need to simulate the airfoils and to avoid a moving mesh. I was able to move the post processing files (surface via probe in OF-Format) files to constant/boundaryData/inlet for each time step and add the correct header (comparable to the example for timeVaryingMappedFixedValue, just for each time step I resolved).

Two questions arose to me:

1. Will OpenFoam interpolate the timesteps inbetween?

2. How do I handle the fact that the amount of points differ between the time steps? So far I used probed via a cutting plane surface. This results in the aforementioned different amout of points and thus in this error:

Quote:
Create time

Create mesh for time = 0

Reading field p



--> FOAM FATAL ERROR:
Number of values (38623) differs from the number of points (38748) in file "./test_inlet_from_slice/constant/boundaryData/inlet/4e-05/p"

From function timeVaryingMappedFixedValueFvPatchField<Type>::che ckTable()
in file fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.C at line 425.

FOAM exiting
I put a points file into the folder (from a random time step) of the inlet patch below the folders of each time step (caparable to the tutorial case in incompressible/simpleFoam/pitzDailyExptInlet). I could provide the points file for each time step though, I just have no clue how to make use of it).

Any help to solve this is appreciated. Since the flow is complex i cannot discribe it via GroovyBC though.

Sincerely,

Henning

Last edited by HenningW; August 22, 2016 at 04:55.
HenningW is offline   Reply With Quote

Old   October 7, 2024, 11:47
Default Watch out for triangulation and interpolation
  #2
New Member
 
Enrico Pivato
Join Date: Nov 2023
Posts: 1
Rep Power: 0
pivee_ is on a distinguished road
Hi everyone,
It's been a long time since this thread is opened and still no replies. I just want to know if someone has an idea of how to deal with the number of values that differs from the number of points. I obviously know that I should change the "input geometry" in order to have the same points. But in my case I can't do that so I was asking if there are some way to process the values in order to have the same number of points.
Additionaly, do you have any idea of how is the order of the values saved? Same order as the points in the corrisponding face?
I mean, if my face has points: (213 3893 1 984)
then the values saved iby my sample process would be:
value(1)
value (213)
value (984)
value (3893) ?


Thanks a lot for any help,
Enrico


EDIT: I got the solution. I was running the sampling without the options 'interpolate' and 'triangulate' so the number of point that I had from sampling was different from the number of field values (actually, idk why)
So i tried to add:

triangulate false;
interpolate true;

to my function for sampling and it works. From what I could learn, triangulate false decrease the number of values for fields (in my case from 800 to 400) and then with interpolation it can increase (in my case from 400 to 451)

I'm sorry for my low level question but I'm still a begineer with OF.
Hope it cen helps someone!

Last edited by pivee_; October 8, 2024 at 07:05. Reason: Resolved my issue
pivee_ is offline   Reply With Quote

Reply

Tags
boundary conditions, points, sample surface, timevaryingmappedfixedval

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
High Courant Number @ icoFoam Artex85 OpenFOAM Running, Solving & CFD 11 February 16, 2017 14:40
time step directories naming issue Andrea_85 OpenFOAM 3 April 3, 2014 09:38
AMI interDyMFoam for mixer nu problem danny123 OpenFOAM Programming & Development 8 September 6, 2013 03:34
mixerVesselAMI2D's mass is not balancing sharonyue OpenFOAM Running, Solving & CFD 6 June 10, 2013 10:34
plot over time fferroni OpenFOAM Post-Processing 7 June 8, 2012 08:56


All times are GMT -4. The time now is 04:59.