class_docstr: Representation of a torus knot or link.
  
  A torus knot is one that can be drawn on the surface of a
  torus. It is parameterised by two integers p and q as below; in
  fact this returns a single knot (a single curve) only if p and q
  are coprime, otherwise it describes multiple linked curves.
  
  Parameters
  ----------
  p : int
      The number of times the knot winds around the outside of the
      torus. Defaults to 2.
  q : int
      The number of times the knot passes through the hole in the
      centre of the torus. Defaults to 3.
  num_points : int
      The number of points in the returned piecewise linear
      curve. If there are multiple curves (i.e. a torus link), this
      is the number of points in *each* curve.  Defaults to 100.
  major_radius : float
      Distance from the center of the torus tube to the center of the torus.
      Defaults to 10.
  minor_radius : float
      The radius of the torus tube. Defaults to 5.
class_docstr_tok: ["Representation","of","a","torus","knot","or","link",".","A","torus","knot","is","one","that","can","be","drawn","on","the","surface","of","a","torus",".","It","is","parameterised","by","two","integers","p","and","q","as","below",";","in","fact","this","returns","a","single","knot","(","a","single","curve",")","only","if","p","and","q","are","coprime",",","otherwise","it","describes","multiple","linked","curves",".","Parameters","--","--","--","--","--","p",":","int","The","number","of","times","the","knot","winds","around","the","outside","of","the","torus",".","Defaults","to","2.","q",":","int","The","number","of","times","the","knot","passes","through","the","hole","in","the","centre","of","the","torus",".","Defaults","to","3.","num_points",":","int","The","number","of","points","in","the","returned","piecewise","linear","curve",".","If","there","are","multiple","curves","(","i.e",".","a","torus","link",")",",","this","is","the","number","of","points","in","*","each","*","curve",".","Defaults","to","100.","major_radius",":","float","Distance","from","the","center","of","the","torus","tube","to","the","center","of","the","torus",".","Defaults","to","10.","minor_radius",":","float","The","radius","of","the","torus","tube",".","Defaults","to","5","."]
docstr: A list of the vertices in each line of the torus knot or link.
  Even if p and q are coprime, this is a list with just one
  entry.
docstr_tok: ["A","list","of","the","vertices","in","each","line","of","the","torus","knot","or","link",".","Even","if","p","and","q","are","coprime",",","this","is","a","list","with","just","one","entry","."]
code: def components(self):
      """A list of the vertices in each line of the torus knot or link.
      Even if p and q are coprime, this is a list with just one
      entry.
      """
      return self._components
  
file_path: vispy/vispy/geometry/torusknot.py
imports: from __future__ import division
  import numpy
  from math import gcd
label_desc: Use image node_id 4 for calling the TorusKnot obj's underlying member method code with example usage: obj.components() and returns: self