
Why Custom Components Matter
Engineering teams are often held back by rigid tools and fragmented workflows. Standard libraries are powerful, but no real-world system ever fits perfectly inside a predefined toolbox. Maybe your actuator has nonlinear friction, or your power converter has a custom efficiency curve. At some point, you need to move beyond built-in blocks and create your own.
That’s where Dyad’s component system shines. With Dyad, you can turn domain knowledge into reusable, acausal components that behave just like the standard library ones. You define the physics once, and then reuse it across projects; no more copy-pasting equations or hacking one-off scripts.
Benefits of Building Components
Reusability: Once built, your component is as portable as a resistor or spring
Maintainability: No more spaghetti equations scattered through notebooks
Composability: Your custom parts plug seamlessly into larger system models
Fidelity: Capture the real behavior of your system instead of forcing it into approximations
How It Works in Dyad
In this webinar, we walk through building electrical components from scratch and assembling them into a full RLC circuit. Here’s what to expect:
1. Define the Interface (Connectors)
Everything starts with connectors, the points where components exchange physical quantities.
For electrical systems, that’s voltage (potential) and current (flow)
Dyad already includes standard connectors like
Pin
andNode
, but you can define new ones if your domain requires it
2. Create Basic Components
With connectors in hand, you write the governing equations:
Resistor:
v = R * i
Capacitor:
i = C * der(v)
Inductor:
v = L * der(i)
Each is written as a component
in Dyad, with clear parameters and relations.
3. Assemble a System Model
Once components exist, connecting them is straightforward.
A
StepVoltage
source drives the circuitA resistor, capacitor, and inductor are wired together with a ground reference
The result: a fully assembled RLC circuit
5. Run an Analysis
Finally, you define a TransientAnalysis
to simulate the response over time. We observe the voltage across the capacitor and current through the inductor over the course of the simulation.
Why This Approach Is Different
Legacy tools often make custom component creation painful. GUI-based tools force you to dig into proprietary blocks or write clumsy masked subsystems. Script-only tools give you flexibility, but no composability - everything becomes a one-off equation dump.
Dyad strikes the balance:
Declarative: You write physics, not solvers
Acausal: No need to predefine inputs vs outputs
Julia-native: Full access to SciML, optimization, ML, and more
The result: your custom model looks, feels, and behaves just like a built-in block - but tailored to your system.
Closing Thoughts
Creating components in Dyad means you’re not limited by what comes in the box. You can extend the language of modeling itself, capturing the unique physics that make your system work.
Watch the Webinar:
Tutorial: https://help.juliahub.com/dyad/dev/tutorials/creating-components.html