def _print_Pure(self, e): if self._use_unicode: symb = pretty_symbol(u"\u2118") else: symb = pretty_symbol('pure') return prettyForm(symb)
def _print_FiniteField(self, expr): if self._use_unicode: form = u'\u2124_%d' else: form = 'GF(%d)' return prettyForm(pretty_symbol(form % expr.mod))
def _print_KroneckerDelta(self, e): pform = self._print(e.args[0]) pform = prettyForm(*pform.right((prettyForm(',')))) pform = prettyForm(*pform.right((self._print(e.args[1])))) if self._use_unicode: a = stringPict(pretty_symbol('delta')) else: a = stringPict('d') b = pform top = stringPict(*b.left(' ' * a.width())) bot = stringPict(*a.right(' ' * b.width())) return prettyForm(binding=prettyForm.POW, *bot.below(top))
def _print_KroneckerDelta(self, e): pform = self._print(e.args[0]) pform = prettyForm(*pform.right((prettyForm(',')))) pform = prettyForm(*pform.right((self._print(e.args[1])))) if self._use_unicode: a = stringPict(pretty_symbol('delta')) else: a = stringPict('d') b = pform top = stringPict(*b.left(' '*a.width())) bot = stringPict(*a.right(' '*b.width())) return prettyForm(binding=prettyForm.POW, *bot.below(top))
def _print_Symbol(self, e): symb = pretty_symbol(e.name) return prettyForm(symb)