finding the minimum of an equation | Traders Hideout


futures.io - futures trading strategies, market news, trading charts and platforms


Traders Hideout


Discuss day trading practices and futures trading strategies on this forum for all markets. This forum is also for discussing and reviews for brokers, data feeds, and commercial or third party add-ons




 

finding the minimum of an equation

  #7 (permalink)

New York, NY
 
Trading Experience: Beginner
Platform: Vanguard 401k
Broker/Data: Yahoo Finance
Favorite Futures: Mutual funds
 
Posts: 1,046 since Jul 2012
Thanks: 718 given, 2,147 received

You need to distinguish between symbolic and numerical differentiation here. There's 3 different approaches depending on what you're trying to do:

If you're trying to find the analytical form of the first derivative, f' and solve the root for it, and you know the analytic formula of f at compile-time, you can solve f'=0 by hand and hard-code that into your program. Or you can find f' and then get quadratic convergence on the minimum with Newton-Raphson.

If you know the analytic form of f at runtime, there's different ways to perform symbolic differentiation, and chain rule-based approaches are popular, e.g. in backpropagation literature for neural networks.

If you don't know the analytic formula of f either at compile-time or runtime, you can still use Newton-Raphson but approximate f' numerically with any finite difference method (secant, forward difference, backward difference, central difference), then converge on f'=0 iteratively.

Reply With Quote
The following 2 users say Thank You to artemiso for this post: