I am currently writing a program that contains a two dimensional newton raphson sub. it starts like this:
Sub newton11()
Dim x As Double, z As Double, tolerance As Double
Dim error_x As Double, error_z As Double
Dim iteration As Integer
iteration = 0
tolerance = 0.05
x = Range("h19").value
z = Range("h20").value
however when I run the sub, it doesn't work. When I was debugging I noticed when I hovered over x it was assigned a value of -344 when Range("h19") is 53 and z was assigned -5.12 when Range("20") is 0.
does anybody know how to fix this?