(string)
| 155 | |
| 156 | |
| 157 | def fix_sqrt(string): |
| 158 | if "\\sqrt" not in string: |
| 159 | return string |
| 160 | splits = string.split("\\sqrt") |
| 161 | new_string = splits[0] |
| 162 | for split in splits[1:]: |
| 163 | if split[0] != "{": |
| 164 | a = split[0] |
| 165 | new_substr = "\\sqrt{" + a + "}" + split[1:] |
| 166 | else: |
| 167 | new_substr = "\\sqrt" + split |
| 168 | new_string += new_substr |
| 169 | return new_string |
| 170 | |
| 171 | |
| 172 | def strip_string(string): |