Skip to content

Instantly share code, notes, and snippets.

@terjehaukaas
Last active June 12, 2019 05:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save terjehaukaas/51d10faefc38aaa400e24077dca8e0b8 to your computer and use it in GitHub Desktop.
Save terjehaukaas/51d10faefc38aaa400e24077dca8e0b8 to your computer and use it in GitHub Desktop.
steepestDescentSearchDirection()
# ------------------------------------------------------------------------
# The following function is implemented in Python by Professor Terje Haukaas
# at the University of British Columbia in Vancouver, Canada. It is made
# freely available online at terje.civil.ubc.ca together with notes,
# examples, and additional Python code. Please be cautious when using
# this code; it may contain bugs and comes without any form of warranty.
# ------------------------------------------------------------------------
def steepestDescentSearchDirection(gradient):
return np.multiply(gradient, -1.0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment