Skip to content

Commit

Permalink
Merge 64623e7 into a9b00c8
Browse files Browse the repository at this point in the history
  • Loading branch information
thebhatman committed Jun 25, 2019
2 parents a9b00c8 + 64623e7 commit 79eb94f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rules.jl
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ _abs_deriv(x) = signbit(x) ? -one(x) : one(x)
@define_diffrule Base.:*(x, y) = :( $y ), :( $x )
@define_diffrule Base.:/(x, y) = :( inv($y) ), :( -($x / $y / $y) )
@define_diffrule Base.:\(x, y) = :( -($y / $x / $x) ), :( inv($x) )
@define_diffrule Base.:^(x, y) = :( $y * ($x^($y - 1)) ), :( ($x^$y) * log($x) )
@define_diffrule Base.:^(x, y) = :( $y * ($x^($y - 1)) ), :( $x > 0 ? ($x^$y) * log($x) : NaN )

if VERSION < v"0.7-"
@define_diffrule Base.atan2(x, y) = :( $y / ($x^2 + $y^2) ), :( -$x / ($x^2 + $y^2) )
Expand Down

0 comments on commit 79eb94f

Please sign in to comment.