implemented gain node