proc SCHEMATIC_period_avg_inverse {} {
make input -name in -origin {260 270}
make output -name out -origin {410 270}
make input -name clk -origin {260 340}
}

proc ICON_period_avg_inverse args {
  icon_setup $args {{origin {0 0}} {orient R0} {name x} {gain 1.0}}
icon_term -type input -origin {-80 0} -name in
icon_term -type input -origin {-80 30} -name clk
icon_term -type output -origin {80 0} -name out
icon_property -origin {-70 0} -label in
icon_property -origin {-70 30} -label clk
icon_property -origin {70 0} -anchor e -label out
icon_property -origin {-70 -50} -label {$name}
icon_property -origin {-70 -30} -label avg_period_inverse
  icon_line -80 -40 80 -40 80 50 -80 50 -80 -40
icon_property -origin {-70 60} -label {gain=$gain}
  icon_property -origin {-90 110} -type user -name name -default x
  icon_property -origin {-90 130} -type user -name gain -default 1.0
icon_property -origin {0 40} -anchor center -label {out = gain/in}
}

