[ 3 / biz / cgl / ck / diy / fa / ic / jp / lit / sci / vr / vt ] [ index / top / reports ] [ become a patron ] [ status ]
2023-11: Warosu is now out of extended maintenance.

/sci/ - Science & Math


View post   

File: 4 KB, 340x148, images[1].png [View same] [iqdb] [saucenao] [google]
12107832 No.12107832 [Reply] [Original]

I made a way to smooth functions. Here is a polynomial being smoothed:
https://www.desmos.com/calculator/cpvrudoiz7

What applications does this have?

>> No.12107857

Here's a crude smoothing of the step function https://www.wolframalpha.com/input/?i=0.5*%28%2810-+x%29*Heaviside%28-10%2B+x%29+%2B+%2810%2B+x%29*Heaviside%2810+%2B+x%29%29%2F10

>> No.12107870

>>12107832
sine wave being smoothed:
https://www.desmos.com/calculator/il99dievkl

>> No.12107875

>>12107832
Define smooth

>> No.12107876

>>12107875
make things less jagged

>> No.12107881

>>12107876
Try in terms of differentiability. That would also provide light on your question.

>> No.12107883

>>12107881
My technique potentially works to make nondifferentiable functions like abs() continuous, haven't tried though

>> No.12107886

>>12107883
abs() is already continuous... it is also differentiable anywhere except its minima and maxima

>> No.12107889

>>12107886
I mean make it smooth

>> No.12107896

you might be mixing up continuity and differentiability.

>> No.12107900

>>12107889
Can you explain what smooth means? Like literally... saying less jagged does not really provide clarity. Either define smooth mathematically, or show us geometri ally.

>> No.12107901

>>12107876
Quantify "less jagged"

>> No.12107905 [DELETED] 

>>12107900
I'm talking about smoothing like filters like the savgol filter in scipy. The input is jagged and the output is smoother

>> No.12107907

>>12107900
I'm talking about smoothing like filters like the Savitzky-golay filter, but mine works on functions. The input is jagged and the output is smoother

>> No.12107908

>>12107905
Variable memory input XOR dynamic speed translator.

>> No.12107909

>>12107832
smooth = infinitely differentiable
you're misusing standard terminology

>> No.12107912

>>12107909
redefining it.

the death of language's ego

>> No.12107915
File: 27 KB, 640x480, images (40).jpg [View same] [iqdb] [saucenao] [google]
12107915

>>12107875
no sharp

>> No.12107920

>>12107915
polynomial fluid dynamics and limits

>> No.12107932

smoothing a fifth degree polynomial https://www.desmos.com/calculator/nxvuwfk1ax

>> No.12107951

>>12107932
I've found another smoothing technique, check this out
https://www.desmos.com/calculator/a0d3owy2fp

>> No.12107960
File: 109 KB, 1200x762, 1200px-WeierstrassFunction.svg[1].png [View same] [iqdb] [saucenao] [google]
12107960

>>12107951
looks similar, it flips the function for delta>1

I tried to smooth this function but I couldn't take the integral

>> No.12107962

How does it work for data with stochastic nose, and is it computationally fast?

>> No.12107964

>>12107912
based

>> No.12107971

>>12107962
It can smooth any polynomial. If you fit a polynomial to the data then it can smooth it. It's fast for polynomials, it can't compute complicated functions though, because it involves integration

>> No.12107995

>>12107971
Sorry for asking such a n00b question but how does one make a polynomial that isn't smooth to begin with?

>> No.12107998

>>12107995
For example if you make a lagrange polynomial it will be extreme because it will overfit the data, but a smoothing method will keep the values in range

>> No.12108002

>>12107998
Then why the fuck would I bother making a lagrange polynomial in the first fucking place?

>> No.12108007

>>12108002
That's not an application, he just asked how a polynomial could not be smooth

>> No.12108028 [DELETED] 
File: 12 KB, 378x248, index.png [View same] [iqdb] [saucenao] [google]
12108028

Smoothed abs(x)

>> No.12108031
File: 12 KB, 378x248, index.png [View same] [iqdb] [saucenao] [google]
12108031

abs(x)

>> No.12108035
File: 9 KB, 215x234, 1585491076230.jpg [View same] [iqdb] [saucenao] [google]
12108035

>>12108031
That's a cool hat bruh.

>> No.12108042
File: 23 KB, 380x248, a.png [View same] [iqdb] [saucenao] [google]
12108042

>>12107960
Smoothed it

>> No.12108049

>>12108042
Looks like an awesome snake to me if it was only made out of its spine and the patterns on the skin, but without the actual skin.

>> No.12108066
File: 20 KB, 380x248, index.png [View same] [iqdb] [saucenao] [google]
12108066

>> No.12108075
File: 21 KB, 380x248, index.png [View same] [iqdb] [saucenao] [google]
12108075

>> No.12108078

If you want to try it, take the integral of f(x) from x-delta to x+delta several times. It works best if you do it infinitely many times.

>> No.12108081

>>12108078
I agree, everything is better when you do it infinitely many times. I remember all those things I did infinite many times.

Ah, those were the categorical imperatives of my exploration.

>> No.12108135 [DELETED] 
File: 25 KB, 386x248, a.png [View same] [iqdb] [saucenao] [google]
12108135

>> No.12108189
File: 26 KB, 386x248, a.png [View same] [iqdb] [saucenao] [google]
12108189

>> No.12108320

>>12107832

does it work for x(x+1)/2

>> No.12109447

>>12108320
Yep. Quadratic

>> No.12109538

>>12109447
>>12108320
tested it, it doesn't work

>> No.12109546

it works, but x(x+1)/2 is smooth so it doesn't change https://www.desmos.com/calculator/pzud5aw3jo

>> No.12109548

it works by interpolating nearby values, so a parabola doesn't change by much

>> No.12109881

>>12107832
Signal denoising kek

>> No.12109909

Study low pass filters. You can probably tune one to smooth however you want.

>> No.12109919

>>12109909
samefagging to say: I would come up with a metric for smoothness because your idea of "smooth" is still not well defined. Some people have asked if you mean removing discontinuities or places where it's not continuously differentiable, and you don't mean that. Try figuring out what you mean by smooth and testing different methods.

I'd look at the fourier transform before and after smoothing and see if that shows the difference you're noticing in the high frequency end.

>> No.12109963

>>12107951
lol, genius. i simplified your discovery further. can we split the nobel prize?
https://www.desmos.com/calculator/8rq4idll8m

>> No.12109977

Why dont you just do it better, like me
https://www.desmos.com/calculator/10wkzfwy8h

>> No.12109985

What the fuck is this thread

>> No.12109989

>>12109985
Methods of smoothing

>> No.12109990

>>12109985
integropolynomial interpolation

>> No.12110008

is this smooth?
https://www.desmos.com/calculator/mnugjqauzc

>> No.12110029

i call this art "smooth criminal"
https://www.desmos.com/calculator/j0ixwyhihw

>> No.12110092

I submitted it to vixra. Here's the pdf if you want to read: https://drive.google.com/file/d/1VzzvxT5XDhBIAuPjbsy_c9ItKjbVvJ6R/view?usp=sharing

>> No.12110520

>>12107998
What the fuck are you even talking about? A Lagrange polynomial is smooth and can't be any smoother. Does your technique make it infinitely+1 differentiable?

>> No.12111383
File: 14 KB, 598x227, 1590857525204.png [View same] [iqdb] [saucenao] [google]
12111383

>>12107832
That has been done before and is a standard trick in analysis. You usually just do the same trick as with kernel smoothers from statistics but instead of a weighted sum you have a weighted integral.
One aplication is often when you want to show that some subset of smooth functions is dense in some Banachspace.
For example to proof that the set of smooth functions with compact support is dense in L^p you usually use an approximation of the L^p function by smoothing it with such a kernel.

>> No.12111413
File: 63 KB, 1000x885, 1481839809871.png [View same] [iqdb] [saucenao] [google]
12111413

>>12110092
>>12111383
to add on this:
It looks like what you are doing is exactly what i described where your kernel function k(x,y) is 1 when |x-y|<delta and 0 otherwise. you seem to have also failed to mention, that you devide the result by 2delta or else the resulting function should go to 0 as delta goes to zero.

>> No.12111429

>reinventing the wheel
>presenting it as a breakthrough
>redefining words
>paper on vixra

We have reached peak /sci/

>> No.12111447

>>12107886
Sorry if I'm being retarded, but abs(x) is not continuous, because its derivative is not continuous. It goes from -1 to 0 to 1 literally instantly.

>> No.12111453

>>12111413
Yeah you divide it by 2*delta every time you integrate, I forgot to mention that. A google search didn't show the method. At least my paper will show up when someone searches

>> No.12111456

>>12111447
|x| is continuous, what are you talking about

>> No.12111457 [DELETED] 

>>12111447
That's sign(x) not abs(x)

>> No.12111470

>>12111447
it is continuous but not continuously differentiable

>> No.12111479

>>12110520
Sharpness is caused by high curvature. Lagrange polynomials tend to have high curvature

>> No.12111488

>inefficient approximation to to the Gauß filter
Revolutionary.

>> No.12111499

>>12110520
OP doesn't what smoothness means. ignore it