docstr: Builds a list of single dimensional variables representing current variable.
  
  Examples:
  For single dimensional variable, it is returned as is
  discrete of (0,2,4) -> discrete of (0,2,4)
  For multi dimensional variable, a list of variables is returned, each representing a single dimension
  continuous {0<=x<=1, 2<=y<=3} -> continuous {0<=x<=1}, continuous {2<=y<=3}
docstr_tok: ["Builds","a","list","of","single","dimensional","variables","representing","current","variable",".","Examples",":","For","single","dimensional","variable",",","it","is","returned","as","is","discrete","of","(","0,2,4",")","-",">","discrete","of","(","0,2,4",")","For","multi","dimensional","variable",",","a","list","of","variables","is","returned",",","each","representing","a","single","dimension","continuous","{","0","<","=x","<","=1",",","2","<","=y","<","=3","}","-",">","continuous","{","0","<","=x","<","=1","}",",","continuous","{","2","<","=y","<","=3","}"]
code: def expand(self):
      """
      Builds a list of single dimensional variables representing current variable.
  
      Examples:
      For single dimensional variable, it is returned as is
      discrete of (0,2,4) -> discrete of (0,2,4)
      For multi dimensional variable, a list of variables is returned, each representing a single dimension
      continuous {0<=x<=1, 2<=y<=3} -> continuous {0<=x<=1}, continuous {2<=y<=3}
      """
      expanded_variables = []
      for i in range(self.dimensionality):
          one_d_variable = deepcopy(self)
          one_d_variable.dimensionality = 1
          if self.dimensionality > 1:
              one_d_variable.name = "{}_{}".format(self.name, i + 1)
          else:
              one_d_variable.name = self.name
          one_d_variable.dimensionality_in_model = 1
          expanded_variables.append(one_d_variable)
      return expanded_variables
  
imports: import numpy
  from copy import deepcopy
  from ..errors import InvalidConfigError
label_desc: Use image node_id 3 for calling the Variable obj's underlying member method code with example usage: obj.expand() and returns: expanded_variables