James' blog

Programming and System Administration

Monday, January 11, 2010

Matlab - simple newton's method ex



function r = doNewton(f,x0,x,err)

while abs(x0 - x) > err

x0, (x0 - x)

x0 = x0 - (polyval(f,x0))/polyval(polyder(f),x0);


end



r = x0;
end

Posted by james at 12:52 PM
Labels: math, matlab, programming

No comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Labels

programming (41) scripting (35) shell (25) windows (22) cmd (12) math (12) matlab (12) sysadmin (12) tools (12) unix (12) linux (11) java (8) mac (7) vbscript (6) design (5) database (4) mobile (4) sed (4) .net (1) awk (1) web-server (1)

Blog Archive

  • ►  2011 (4)
    • ►  November (1)
    • ►  September (1)
    • ►  June (2)
  • ▼  2010 (11)
    • ►  May (1)
    • ►  April (2)
    • ►  March (3)
    • ►  February (1)
    • ▼  January (4)
      • Mortgage calculator - bash script
      • start menu pin list location
      • Bash - Gaussian Elimination Op count example
      • Matlab - simple newton's method ex
  • ►  2009 (73)
    • ►  November (4)
    • ►  October (9)
    • ►  September (2)
    • ►  August (6)
    • ►  July (1)
    • ►  June (35)
    • ►  May (13)
    • ►  April (3)
  • ►  2008 (5)
    • ►  December (2)
    • ►  August (3)
Watermark theme. Powered by Blogger.