#NEWLINE# def __radd__( p1 , n ) : #NEWLINE# #INDENT# p = p1 . copy ( ) #NEWLINE# if ( not n ) : #NEWLINE# #INDENT# return p #NEWLINE# #UNINDENT# ring = p1 . ring #NEWLINE# try : #NEWLINE# #INDENT# n = ring . domain_new ( n ) #NEWLINE# #UNINDENT# except CoercionFailed : #NEWLINE# #INDENT# return NotImplemented #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# zm = ring . zero_monom #NEWLINE# if ( zm not in p1 . keys ( ) ) : #NEWLINE# #INDENT# p [ zm ] = n #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( n == ( - p [ zm ] ) ) : #NEWLINE# #INDENT# del p [ zm ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# p [ zm ] += n #NEWLINE# #UNINDENT# #UNINDENT# return p