Rank: 5731 based on 0 downloads (last 30 days) and 1 file submitted
photo

Keith Sudheimer

E-mail
Company/University
Stanford University

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Files Posted by Keith
Updated   File Tags Downloads
(last 30 days)
Comments Rating
01 Oct 2009 GoalFind Do the opposite of any single variable function or transformation Author: Keith Sudheimer reverse functions fun... 0 1
  • 2.0
2.0 | 1 rating
Comments and Ratings on Keith's Files
Updated File Comment by Comments Rating
03 Oct 2009 GoalFind Do the opposite of any single variable function or transformation Author: Keith Sudheimer Simon, Jan

It works, it has a help text (but not at the usual location) and some comments, but no H1-line.
Mathematically, the algorithm is weak: The formula is calculated at 1000 equidistant steps of the allowed interval. Then one point with the smalles difference to the wanted value is picked out and the new interval is limited to the mean of this point and the old interval limits. The check of reaching the goal does not consider a tolerance, but checks for equality.
This strategy can fail e.g. for periodical values (SIN, COS) and the choice of the new limits is more or less arbitrary. There are much better methods to find a solution of the function F(x) - y = 0, e.g. Matlab's FZERO, FMINBND. Using the processing time as termination criterion effects a randomness of the result, especially if TIC/TOC is used to measure the time: The result depends on the procesor speed and the activity of background processes! The number of iterations is better to create reproducible results.
Using anonymous functions or function handles as input is better than defining the function as string and replacing all 'N' - what will happen for the function 'mySIN(N)' ?!

Top Tags Applied by Keith
reverse functions functions
Files Tagged by Keith
Updated   File Tags Downloads
(last 30 days)
Comments Rating
01 Oct 2009 GoalFind Do the opposite of any single variable function or transformation Author: Keith Sudheimer reverse functions fun... 0 1
  • 2.0
2.0 | 1 rating

Contact us at files@mathworks.com