Save 15% On All Single Licences! Loading... GET OFFER

How to Use Parameters and Constraints in BricsCAD BIM

Quick answer: Parametric modeling in BricsCAD works through geometric and dimensional constraints, controlling the 2D and 3D geometric model with parameters. Each parameter displays with its value in the Mechanical Browser, and values link together via expressions; changing one automatically updates the geometric model. Confirming the note from this hub’s parametric modeling overview page: there are no parent-child dependencies between geometric elements by default, changing a sketch used to create an extruded solid doesn’t change the solid, any dependency has to be built deliberately using parameters and expressions.

Local vs Global Parameters

Local parameters attach to a particular entity. Global parameters don’t attach to any specific entity.

Geometric Constraints

Access via Toolbar (Parametric > 3D constraints) or the Quad’s Constraints tab.

Constraint What it does
Fix Keeps solids, edges, or faces of solids in place in the drawing
Coincident Applies a coincident constraint between two edges, two faces, or an edge and a face of two different solids
Concentric Keeps two cylindrical, spherical, or conical surfaces centred
Parallel Keeps two faces of a solid, or of different solids, parallel
Perpendicular Keeps two faces of a solid, or of different solids, perpendicular
Tangent Keeps a face and a curved surface of different solids tangent
Rigid set Makes a set of entities or sub-entities a rigid body

Dimensional Constraints

Access via Toolbar (Parametric > 3D constraints), the Quad’s Constraints tab, or the Parametric ribbon tab’s 3D constraints panel.

Constraint What it does
Distance Creates a distance between two sub-entities
Radius Creates a radius on cylindrical surfaces or circular edges
Angle Creates an angle between two faces of a solid, or of different solids

Setting an Expression to a Parameter

Any parameter, global or local, can carry an expression, from a simple number or global parameter name to a more complex formula using standard operators and functions. Local parameters can’t be referenced by name in expressions. The constants Pi (3.14…) and e (2.72…) are usable in expressions, and their names can’t be reused as parameter or constraint names.

Operators: addition (+), subtraction or negative (-), multiplication (*), division (/), exponentiation (^), and modulo/remainder (%, for example, 5 % 2 evaluates to 1, since 5 divided by 2 leaves a remainder of 1).

Functions: sin(), cos(), tan(), asin(), acos(), atan(), sinh(), cosh(), tanh(), asinh(), acosh(), atanh(), sqrt(), sign() (returns -1, 0, or 1), round(), trunc(), floor(), ceil(), abs(), max(expression1;expression2), min(expression1;expression2), d2r() (degrees to radians), r2d() (radians to degrees), ln(), log() (base 10), exp(), exp10(), pow(expression1;expression2), and Random (a random decimal between 0 and 1). For max, min, and pow, use your system’s list separator character, a comma or semicolon.

This confirms the exact operator and function list documented on this hub’s operations and functions in expressions page, worth noting since a related but distinct syntax, Field Formula, differs slightly (using tang() instead of tan(), and including a Field-Formula-only sqr() function not present here).

Parametric Blocks

A parametric block has parameters that determine its 3D geometry’s size and shape. Once created, insert it as a block reference, then change its parameters after insertion without needing to modify the block file itself, letting the same block appear in different sizes and shapes throughout your model.

Parametrizing a Custom Component: A Full Worked Example

This continues the custom window built on this hub’s window and door creation page, made of three solids: subtractor, fixed frame, and glass pane.

Before adding constraints:

  1. Open the Mechanical Browser with MECHANICALBROWSEROPEN to manage the drawing’s 3D constraints and parameters.
  2. Make sure Enable selection of 3D solid faces is toggled on under Selection Modes, and Boundary Detection is toggled off to make the following steps easier.

Applying fix constraints (DMFIX3D):

  1. Turn on the BC_SUBTRACT layer.
  2. Select the entities you want to fix.
  3. Optionally press Tab to select obscured geometry.
  4. Choose Add Fixation from the 3D constraints command group in the Quad; the fixation appears in the Mechanical Browser as Fix_1.

Applying rigid constraints (DMRIGIDSET3D):

  1. Select the entities you want in a Rigid Set (entities stay in the same position relative to each other once grouped this way). To select multiple sub-entities of the same type at once: switch to Top view using the LookFrom control, then draw a selection box, pressing Ctrl to cycle through sub-entity selection types (faces, edges, and so on, shown under the cursor; selection boxes default to selecting whole solids).
  2. Choose Add Rigid Set from the 3D constraints command group in the Quad.
  3. Repeat for the other sides: top, bottom, and right.

Applying distance constraints (DMDISTANCE3D):

  1. Turn off the BIM_Subtract layer.
  2. Select the first face; it highlights.
  3. Hover over the second face (press Tab for an obscured one).
  4. Once it highlights, choose Add Distance from the 3D Constraints command group in the Quad; you’re prompted for a distance value, or to choose Geometry-driven.
  5. Either press Enter or right-click to accept the current value (shown in the dynamic dimension field if Dynamic Dimensions is active), or type a value at the Command line.
  6. The distance value appears in the Mechanical Browser. To remove any constraint, select it there and press Delete, or right-click and choose Delete.

Applying parameters (creating a parameter to control the window’s width):

  1. Right-click the file name in the Mechanical Browser and choose Add New Parameter; a parameter settings grid appears, and the parameter adds to the Mechanical Browser as v1 = 1.
  2. Select it and edit its properties in the settings grid: Name (the parameter’s name), Expression (a value or formula), Value (its current value, read-only), Geometry-driven (on disables the Expression field), Description (optional), Exposed (controls whether it’s available in the Properties panel once the component is inserted), Units (linear, areal, or volumetric), and BOM status (whether it’s included in a bill of materials).
  3. You can similarly use the Parameters Manager panel to add parameters creating upper and lower limits for the window’s width, combining max() and min() expressions.
  4. To link a parameter to a dimensional constraint, select that constraint in the Mechanical Browser and reference the parameter in the constraint’s Expression field, for example, so that a width parameter (W) of 900 mm drives a distance constraint to 800 mm.
  5. Optionally change the parameter’s expression value and press Enter; the linked distance constraint updates accordingly.

BricsCAD prevents you from applying more constraints than are actually necessary for a given geometry.

Frequently Asked Questions

Can a local parameter be referenced by name in an expression? No, only global parameters can be referenced by name; local parameters are attached to a specific entity and can’t be named in expressions.

Does changing a sketch automatically update a 3D solid extruded from it? No, there are no automatic parent-child dependencies in BricsCAD; any such relationship needs to be built deliberately using parameters and expressions.

What’s the difference between Field Formula expressions and these parameter expressions? They’re mostly identical, but Field Formula uses tang() instead of tan(), and includes a sqr() function not available here.

How do I let a component’s parameters be edited after inserting it into a model? Set the parameter’s Exposed property, which controls whether it’s available in the Properties panel once the component is inserted.

Powered by Full Pelt Ltd