3 ms·
Can it compute y=sin x?
by quickthrower2 8y ago
Can it compute y=sin x?
- hcs 8y ago> First, this doesn't mean that a network can be used to exactly compute any function. Rather, we can get an approximation that is as good as we want. By increasing the number of hidden neurons we can improve the approximation.
- tsbinz 8y agoAlso, the article doesn't mention a crucial part of the universal approximation theorem: It is about functions on compact subsets of R^n, so it doesn't say anything about functions that take the whole of R as input.
- ska 8y agoIt's also important to note the theorem doesn't help you find the right weights, just notes they exist.
- pauljurczak 8y agoThey can't approximate functions on unbound domain in general case.
- fnbr 8y agoA recurrent network can with ease. For a vanilla MLP, you'd need to add in a few previous values (ie you'd predict x_{t+1} = f(x_t, ..., x_{t-N}), where f is your neural network and N is some fixed integer).
- quickthrower2 8y agoDownvoted for asking a genuine question?
- mkl 8y agoI think it's because it looks like you didn't read the article, which explains repeatedly that this is a theorem of universality. Any continuous function will work, and sin is continuous. Check this out: https://www.desmos.com/calculator/rfaqogkbmy https://www.desmos.com/calculator/rfaqogkbmy Try changing f(x) to "sin(x)" or whatever you like (e.g. sin(10x) may be more interesting). Then drag the sliders for w (how step-like the purple pieces are) and n (how many pieces to add together). The function f(x) is red, and the approximation is blue.