---
url: /dyad/stable/stdlib/MultibodyComponents/components/Mux1.md
description: >-
  Dyad Mux1 docs.  Trivial adapter that wraps a single scalar input into a
  1-element vector output. Use when feeding a scalar signal into an array-input
  slot o...
---

# `Mux1` {#Mux1}

Trivial adapter that wraps a single scalar input into a 1-element vector output. Use when feeding a scalar signal into an array-input slot of a larger mux (e.g. the integral-action channel of `LQRControlledRotorCraft`).

## Usage {#Usage}

`MultibodyComponents.Mux1()`

## Connectors {#Connectors}

* `u1` - This connector represents a real signal as an input to a component ([`RealInput`](/stdlib/Dyad/connectors/RealInput#RealInput))

* `y` - This connector represents a real signal as an output from a component ([`RealOutput`](/stdlib/Dyad/connectors/RealOutput#RealOutput))

## Behavior {#Behavior}

$$ \begin{align}
y\_{1}\left( t \right) &= \mathtt{u1}\left( t \right)
\end{align}
$$

## Source {#Source}

```dyad
"""
Trivial adapter that wraps a single scalar input into a 1-element vector
output. Use when feeding a scalar signal into an array-input slot of a
larger mux (e.g. the integral-action channel of `LQRControlledRotorCraft`).
"""
component Mux1
  "Scalar input"
  u1 = RealInput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": -100, "y1": 450, "x2": 0, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  "1-element output vector"
  y = [RealOutput() for i in 1:1] {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 1000, "y1": 450, "x2": 1100, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
relations
  y[1] = u1
end
```

```dyad
"""
Trivial adapter that wraps a single scalar input into a 1-element vector
output. Use when feeding a scalar signal into an array-input slot of a
larger mux (e.g. the integral-action channel of `LQRControlledRotorCraft`).
"""
component Mux1
  "Scalar input"
  u1 = RealInput() {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": -100, "y1": 450, "x2": 0, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
  "1-element output vector"
  y = [RealOutput() for i in 1:1] {
    "Dyad": {
      "placement": {
        "diagram": {"iconName": "default", "x1": 1000, "y1": 450, "x2": 1100, "y2": 550, "rot": 0}
      },
      "tags": []
    }
  }
relations
  y[1] = u1
metadata {}
end
```

## Test Cases {#Test-Cases}

No test cases defined.

## Related {#Related}

* Examples

* Experiments

* Analyses
