title: Define method aliases in Python?
body: <p>I have a vector class and I defined the <code>__mul__</code> method to multiply a vector by a number.</p>
  
  <p>Here is the <code>__mul__</code> method :</p>
  
  <pre><code>def __mul__(self, other):
      x = self.x * other
      y = self.y * other
      new = Vector()
      new.set_pos((x, y))
      return new
  </code></pre>
  
  <p>My problem is that I don't know which is which between the number and the vector.
  If self is the number, self.x raises an error. (I'm maybe mistaking on this point : Is "other" always a number ?)</p>
  
  <p>So I found here : <a href="https://stackoverflow.com/questions/6892616/python-multiplication-override">Python: multiplication override</a>
  that I could do :</p>
  
  <pre><code>__rmul__ = __mul__
  </code></pre>
  
  <p>but how can I do that in a class definition ?</p>
  
  <p>Something like :</p>
  
  <pre><code>def __rmul__ = __mul__
  </code></pre>