Commit 808a6241 authored by Taddeus Kroes's avatar Taddeus Kroes

Added some comments.

parent aa65ad69
...@@ -8,13 +8,15 @@ from ..translate import _ ...@@ -8,13 +8,15 @@ from ..translate import _
def choose_constant(integral): def choose_constant(integral):
""" """
Choose a constant to be added to the antiderivative. Choose a constant to be added to the antiderivative.
Start at 'c', then alphabetically from 'a' until an variable is encountered
that is not occupied in the integral already.
""" """
# TODO: comments
occupied = find_variables(integral) occupied = find_variables(integral)
c = 'c' c = 'c'
i = 96 i = 96
while c in occupied: while c in occupied:
# Skip 'c'
i += 2 if i == 98 else 1 i += 2 if i == 98 else 1
c = chr(i) c = chr(i)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment