diff --git a/source/precalculus/exercises/outcomes/LF/LF4/generator.sage b/source/precalculus/exercises/outcomes/LF/LF4/generator.sage index f289357d..c2896c00 100644 --- a/source/precalculus/exercises/outcomes/LF/LF4/generator.sage +++ b/source/precalculus/exercises/outcomes/LF/LF4/generator.sage @@ -41,9 +41,9 @@ class Generator(BaseGenerator): point5=(point5[0],point5[1]+choice([-4..-1,1..4])) slope = -1*line.lhs().coefficients(x)[1][0]/line.lhs().coefficients(y)[1][0] - if orientation1=="parallel": + if orientation2=="parallel": slope2=slope - elif orientation1=="perpendicular": + elif orientation2=="perpendicular": slope2=-1/slope new_line = y-point5[1]==(x-point5[0]).mul(slope2,hold=True)