def add_internal_coupling(a, b, output_port = nil, input_port = nil)
      a = fetch_child(a) unless a.is_a?(Model)
      b = fetch_child(b) unless b.is_a?(Model)
      raise FeedbackLoopError, "#{a} must be different than #{b}" if a.equal?(b)

      output_port = a.find_or_create_output_port_if_necessary(output_port)
      input_port = b.find_or_create_input_port_if_necessary(input_port)

      _internal_couplings[output_port] << input_port
    end
def add_internal_coupling(a, b, output_port = nil, input_port = nil)
      a = fetch_child(a) unless a.is_a?(Model)
      b = fetch_child(b) unless b.is_a?(Model)
      raise FeedbackLoopError, "#{a} must be different than #{b}" if a.equal?(b)

      output_port = a.find_or_create_output_port_if_necessary(output_port)
      input_port = b.find_or_create_input_port_if_necessary(input_port)

      _internal_couplings[output_port] << input_port
    end
@deprecated Use {#attach} instead.
 Adds an internal coupling (IC) to self. Establish a relation between an
 output {Port} of a first child and the input {Port} of a second child.

 If the ports parameters are ommited, they will be automatically
 generated. Otherwise, the specified ports will be used. If a name is
 given instead

 @param a [Model, String, Symbol] the first child or its name
 @param b [Model, String, Symbol] the second child or its name
 @param output_port [Port, String, Symbol] a's output port or its name
 @param input_port [Port, String, Symbol] b's input port ot its name
 @raise [FeedbackLoopError] if both given children are the same. Direct
   feedback loops are not allowed, i.e, no output port of a component may
   be connected to an input port of the same component