How Can I Improve the Smoothing of Pressure Coefficients in CFD Data?

  • Thread starter Thread starter enigma
  • Start date Start date
  • Tags Tags
    Data
Click For Summary
The discussion focuses on improving the smoothing of pressure coefficients derived from CFD data of a wing shape, which is affected by a minor surface dent. The user has implemented a Gaussian filter but finds it insufficient for achieving the desired smoothness after multiple iterations. They also consider a more complex method involving tangents to the curve but are concerned about computational intensity. A 5th order Butterworth filter was utilized, but it introduced displacement due to a low cutoff frequency, suggesting a trade-off between smoothing and displacement. The user seeks a more effective and elegant solution to enhance data quality.
enigma
Staff Emeritus
Science Advisor
Gold Member
Messages
1,738
Reaction score
20
Hi all,

I'm having a little difficulty processing my data, and I hope someone here will be able to help me out. (files are a MATLAB .m script and a .mat data file zipped up)

The data I have is the shape of a standard wing and the pressure coefficients along the top and bottom surfaces output from CFD code. Unfortunately, there is a minor dent in the surface where the two equations which generated the shape meet (this remains even after filtering). This inconsistancy will not show up in my experimental setup because it will be under the noise level after I sand the wing.

The problem I'm having is with the pressure coefficients returned from the CFD code. The divot causes the Navier Stokes equations to go whacky on that point and it looks like a 1/x term in the region about 0 is superimposed over the curves (running the code shows what I'm talking about... around c=0.15). I would like to smooth this curve out.

I have coded a method which a colleage called a Gaussian filter (looking online for more information has turned up very little... only things with image processing, so the name might not even be correct), which basically takes the secant between the points ahaid and behind the point to be modified, interpolates the value of the point in question which lies on the secant, and averages it with the original value (hope that makes sense). You then run that through for all points to be filtered, and then run the loop until you get clean enough data.

Unfortunately, this is not giving me a smooth enough slope either, even after 10 runs or more, and the improvement is quickly reaching diminishing returns. The code also illustrates this.

I'm considering coding something which will go out from the "asymptote" and find the first two points where the tangent to the curve intersects both of them, but I have a feeling that this will be computationally intensive as well.

I am wondering if there is a more elegant solution which I'm unaware of to solve this problem.

Thanks in advance for your time.
 

Attachments

Mathematics news on Phys.org
I used a 5th order Butterworth filter with cutoff frequency equal to 0.15 of your sampling frequency.
The .txt file is your .m file edited to implement the modification. I also changed the colors of the plot. In blue is your wing profile, in green the raw data and in red the filtered data.
There is a displacement in the filtered data, because the cutoff frequency is too low, in order to achive enough smoothing. If this displacement is undesirable, you can have less displacement with less smoothing by augmenting the cutoff frequency.
 

Attachments

Here is a little puzzle from the book 100 Geometric Games by Pierre Berloquin. The side of a small square is one meter long and the side of a larger square one and a half meters long. One vertex of the large square is at the center of the small square. The side of the large square cuts two sides of the small square into one- third parts and two-thirds parts. What is the area where the squares overlap?

Similar threads

Replies
7
Views
3K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 21 ·
Replies
21
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 45 ·
2
Replies
45
Views
6K
  • · Replies 1 ·
Replies
1
Views
1K
Replies
55
Views
6K