Expressions
Make the values in your design calculate themselves. Type a formula in a property or a layout rule, and Flux updates the value when its inputs change.
Flux has a math expression engine in properties and PCB layout rules. Expressions work like spreadsheet formulas.
Overview
Expressions let you enter math functions as values in many contexts, including object properties and object rules.
Getting Started
This page covers the use cases for expressions:
What is an Expression? learn how to integrate expressions in your project
Expression Results: learn how Flux shows the result of an expression
Basic expressions: learn how to create basic math operations and unit management.
Advanced expressions: learn how to work with more advanced math functions and expressions.
Functions: learn how to use Flux-specific additional functions.
Accessing object data: learn how to access properties and rules inside objects.
Accessing project data: learn how to access project data like a URL or description
What is an Expression?
An expression puts dynamic data into a property or rule. Flux evaluates the expression in real time to calculate the value of the property or rule. For example:
Example: Position Rule
To set the position of an element, change the "Position Y" rule. Usually, you type the final position in the rule, for example 20mm.

With an expression, you can calculate the "Position Y" rule from another rule, like "Position X":

Expression Results
Flux displays an expression result below the input for object properties and object-specific rules, which produce a single value.

Selector-based rules can return multiple results. Flux displays the Outputs multiple values legend in that case.
Basic Expressions
Advanced Expressions
Expressions support math functions, units, unit conversion, and strings.
Flux-specific Function Helpers
Flux adds functions for electronics calculations.
Accessing Object Data
How you access object data depends on whether you use a layout rule or an object property.
Accessing Object Data from a Rule
In a layout rule, the .this directive has this structure:
Examples
Accessing Object Data from a Property
In a property, the .this directive has this structure:
Examples