parameters: (self, Model, settings )
docstring: The default constructor of the class
  
          Keyword arguments:
          self -- It signifies an instance of a class.
          Model -- the container of the different model parts.
          settings -- Kratos parameters containing solver settings.
docstring_summary: The default constructor of the class
docstring_tokens: The default constructor of the class
function: def __init__(self, Model, settings ):
          """ The default constructor of the class
  
          Keyword arguments:
          self -- It signifies an instance of a class.
          Model -- the container of the different model parts.
          settings -- Kratos parameters containing solver settings.
          """
  
          # The value can be a double or a string (function)
          default_settings = KratosMultiphysics.Parameters("""
          {
              "help"                 : "This process assigns a given value (vector) to the nodes belonging a certain submodelpart",
              "mesh_id"              : 0,
              "model_part_name"      : "please_specify_model_part_name",
              "variable_name"        : "SPECIFY_VARIABLE_NAME",
              "interval"             : [0.0, 1e30],
              "value"                : [0.0, 0.0, 0.0],
              "local_axes"           : {},
              "entities"             : ["nodes"]
          }
          """
          )
  
          if not settings.Has("value"):
              raise RuntimeError("Please specify the value to set the vector to. Example:\n" \
                                 + '{\n\t"value" : [10.0, "3*t", "x+y"]\n}\n')
  
          settings.ValidateAndAssignDefaults(default_settings)
  
          # Ensure proper entities
          if settings["entities"].size() != 1:
              settings["entities"] = default_settings["entities"]
          else:
              if settings["entities"][0].GetString() != "nodes":
                  settings["entities"] = default_settings["entities"]
  
          # Construct the base process.
          super(AssignVectorVariableToNodeProcess, self).__init__(Model, settings)
function_tokens: def __init__ ( self , Model , settings ) : # The value can be a double or a string (function) default_settings = KratosMultiphysics . Parameters ( """
          {
              "help"                 : "This process assigns a given value (vector) to the nodes belonging a certain submodelpart",
              "mesh_id"              : 0,
              "model_part_name"      : "please_specify_model_part_name",
              "variable_name"        : "SPECIFY_VARIABLE_NAME",
              "interval"             : [0.0, 1e30],
              "value"                : [0.0, 0.0, 0.0],
              "local_axes"           : {},
              "entities"             : ["nodes"]
          }
          """ ) if not settings . Has ( "value" ) : raise RuntimeError ( "Please specify the value to set the vector to. Example:\n" + '{\n\t"value" : [10.0, "3*t", "x+y"]\n}\n' ) settings . ValidateAndAssignDefaults ( default_settings ) # Ensure proper entities if settings [ "entities" ] . size ( ) != 1 : settings [ "entities" ] = default_settings [ "entities" ] else : if settings [ "entities" ] [ 0 ] . GetString ( ) != "nodes" : settings [ "entities" ] = default_settings [ "entities" ] # Construct the base process. super ( AssignVectorVariableToNodeProcess , self ) . __init__ ( Model , settings )