Convert to a string, using engineering notation if an exponent is needed. Engineering notation has an exponent which is a multiple of 3. This can leave up to 3 digits to the left of the decimal place and may require the addition of either one or two trailing zeros.
(self, context=None)
| 1032 | return sign + intpart + fracpart + exp |
| 1033 | |
| 1034 | def to_eng_string(self, context=None): |
| 1035 | """Convert to a string, using engineering notation if an exponent is needed. |
| 1036 | |
| 1037 | Engineering notation has an exponent which is a multiple of 3. This |
| 1038 | can leave up to 3 digits to the left of the decimal place and may |
| 1039 | require the addition of either one or two trailing zeros. |
| 1040 | """ |
| 1041 | return self.__str__(eng=True, context=context) |
| 1042 | |
| 1043 | def __neg__(self, context=None): |
| 1044 | """Returns a copy with the sign switched. |