Skip to content
Blocks.Gain.md

Blocks.Gain ​

Usage ​

TranslatedComponents.Blocks.Gain(k=1)

Parameters: ​

NameDescriptionUnitsDefault value
k–1

Connectors ​

  • u - This connector represents a real signal as an input to a component (RealInput)

  • y - This connector represents a real signal as an output from a component (RealOutput)

Behavior ​

julia
using TranslatedComponents #hide
using ModelingToolkit #hide
@variables k #hide
@named sys = TranslatedComponents.Blocks.Gain(k=k) #hide
full_equations(sys) #hide
<< @example-block not executed in draft mode >>

Source ​

dyad
component Gain
  u = RealInput()
  y = RealOutput()
  parameter k::Real = 1
relations
  y = k * u
end
Flattened Source
dyad
component Gain
  u = RealInput()
  y = RealOutput()
  parameter k::Real = 1
relations
  y = k * u
metadata {}
end


Test Cases ​

No test cases defined.

  • Examples

  • Experiments

  • Analyses