The LiveLink Node
The LiveLink for Revit feature, available from the LiveLink menu in the Home toolbar, synchronizes the geometry between Revit® and COMSOL Multiphysics®.
For geometry synchronization to take place both COMSOL Multiphysics and Revit® need to be running, and the CAD file needs to be open in the CAD software. When this is not possible, Offline Synchronization is available so that you can, from the CAD software, save synchronization files, which you can load into the LiveLink node.
During synchronization the LiveLink interface generates and transfers the geometry objects for the volumes of selected rooms in the Revit® project, and retrieves and transfers the geometry of architectural elements, including masses. Mass objects are rebuilt before transfer based on the parameter values set in the COMSOL Multiphysics model. To ensure that associativity is preserved use selections for the architectural elements to apply model settings, for example material and physics settings.
In the geometry sequence of the model the LiveLink node signifies a geometry synchronized from the CAD software, and in many aspects it is just like any other geometry operation. It can be combined with other operations that may appear both before and after the LiveLink node in the sequence.
Synchronized geometry objects are represented using the Parasolid® geometry kernel inside COMSOL Multiphysics. Thus, you can apply all the tools and features for defeaturing and geometry modification as included with this LiveLink™ product.
The Synchronize Section
To specify which project to synchronize use the Synchronize with list. Select Active document to synchronize the open and active project in Revit®. For the initial synchronization after adding a LiveLink™ node, Active document is the only available setting. For subsequent synchronizations the Specified document option becomes selected instead. Using this setting the project specified after Document will be synchronized provided that it is open in Revit®. To synchronize a new project switch to the Active document setting. The name of the project is automatically determined during synchronization with the Active document setting.
When running parametric optimization studies or parametric sweeps, the project needs to remain open in Revit® until the solver completes.
The LiveLink interface also determines the selected Configuration in the synchronized Revit® project when Synchronize with is set to Active document. To make sure that the project will be synchronized in the same state during subsequent synchronizations, the Specified document alternative can be used. With this option the interface automatically activates the last synchronized configuration. To be able to synchronize the project in a different configuration, first make the desired configuration active in Revit®, then from the Synchronize with list select Active document.
For information on how to set up synchronization configurations for a Revit® project see the section titled The Synchronization Settings Window.
You can also select to Synchronize material data together with the geometry. With this option the interface imports the material properties defined in the synchronized part or assembly components, and the software creates corresponding Material nodes in the component. The input selection in the generated Material nodes is set to the material selections that are also created during synchronization; see Selections, for more information.
To initiate a synchronization click the Synchronize button. This sends parameter value pairs to Revit®, then retrieves the regenerated geometry objects. Synchronization can also be triggered by clicking a build button when there are changed settings in the LiveLink node, or there are changed parameter values. Synchronization is automatic when running an optimization study or a parametric sweep.
Select the Offline synchronization checkbox to enable the Offline Synchronization section where you can load synchronization files that you have prepared in advance using the LiveLink tools in Revit®. Such offline synchronization files can contain the geometry, selections and parameters for several synchronizations, including parameter sweeps.
Offline Synchronization
Use offline synchronization when you do not have the possibility to run the CAD software and COMSOL Multiphysics on the same computer. For example, to run a parametric sweep when COMSOL Multiphysics is installed on a Linux or macOS computer, you can, in the CAD software, prepare and save in advance a synchronization file with the geometries needed for the sweep. In COMSOL Multiphysics, in the LiveLink node, you can load the synchronization file, and compute the parametric sweep.
To load a synchronization file, from the Offline Synchronization toolbar, click Receive Synchronization File (). Browse to the file and click open to load the geometry, parameters and selections from the file. Synchronization files may contain one or several synchronizations, including synchronizations generated in response to a requested parameter sweep.
If the loaded synchronization file contains a parametric sweep the number of parameter tuples in the file is displayed under Receive. After the file is loaded, you can go to the Study node that contains the parametric sweep for which the synchronization was requested, and click Compute to run the parametric sweep.
In case a loaded synchronization file contains several synchronizations you can see the number of synchronizations left in the file under Receive. To load the next synchronization from the file click Load Next Synchronization ().
To request a synchronization click Request Synchronization (). You can, for example, under Global Definitions > Parameters, change the value of a parameter that is synchronized (see Parameters), and then generate a synchronization request. The response you will generate in Revit® will contain the updated geometry according to the parameter value in the request. To save another request to the previously saved request file click Append to Request File (). To generate a request for a parametric sweep select one of the available sweeps from the Parametric sweep to request list, and then click Request Synchronization to save the request.
Parameters
Parameters that take part in the synchronization are specified in the Parameters in CAD Package section. Based on the transferred parameter and value pairs in the Controllable parameters table, the CAD model is automatically rebuilt in Revit® and transferred back to COMSOL Multiphysics®. This way you can control mass parameters in the Revit mass model.
Together with the updated geometry, updated values of the parameters listed in the Read-only parameters table are also transferred from the CAD software. Read-only parameters are defined by a formula in Revit®, and therefore not possible to control without breaking the CAD design. However these parameters can be used to set up the simulation.
Clicking Synchronize also retrieves parameters that not yet appear in the tables under the Parameter in CAD Package section but have been selected to be linked to COMSOL® from the Revit® project. As part of this process a corresponding global parameter is automatically generated in the model.
In both the Controllable parameters and Read-only parameters tables, the CAD name column holds the names of mass parameters in the Revit® project, whereas the COMSOL name and COMSOL value columns contain the name and value, respectively, of corresponding global parameters in the model, defined under Global Definitions > Parameters in the model tree. Global parameters can be controlled by the parametric solver to perform parametric sweeps. During synchronization of controllable parameters COMSOL evaluates the corresponding global parameters and sends the resulting value to Revit®. Click the symbol in the Sync column to turn on or off the synchronization of a parameter.
Unless a unit is specified the updated parameters are assumed to have units as defined in the Revit® project.
Synchronizing Parameters
You can type in parameters in the tables, or use the COMSOL Parameter Selection window in Revit® to link parameters from the Revit® project, for details see the section The COMSOL Parameter Selection Window. Linked parameters can then be retrieved to the table, and global parameters are automatically generated for them.
To retrieve the linked parameters from the Revit® project to the LiveLink node, and to generate corresponding global parameters in the model do one of the following:
In the Settings window for LiveLink for Revit click the Synchronize button:
New parameters, which have been selected in the Revit® project, but are not listed under Parameters in CAD Package, are transferred to the Controllable parameters table or the Read-only parameters table. For each new mass parameter a global parameter is generated in the model. The global parameters are assigned the values of the corresponding mass parameters. Following this, the geometry is regenerated in Revit®, based on the parameters in the Controllable parameters table, and transferred to COMSOL.
In the Settings window for LiveLink for Revit click the Update Parameters from CAD button ()
New parameters, which have been selected in the Revit® project, but are not listed under Parameters in CAD Package are transferred to the Controllable parameters table or the Read-only parameters table. For each new mass parameter a global parameter is generated in the model. The global parameters are assigned the values of the corresponding mass parameters. In addition, the values of global parameters, which are already linked to mass parameters in the table, are updated to the current values of the mass parameters.
Length Unit
In the Length unit list, select From COMSOL to scale the transferred objects to the length unit of the geometry in the current model. Select From CAD document to change the geometry’s length unit to the unit in the CAD software.
Object Types to Import
Select the types of objects to transfer from Revit® using the Solids, Surfaces checkboxes.
Simplify and Repair
The Absolute import tolerance is a length measured in the geometry’s unit after synchronization. This tolerance is used by some of the simplification and repair operations as detailed in this section. During the import of objects transferred from Revit®, the repair operations are performed in the order of the corresponding settings (starting from the top) in the user interface.
If the Remove redundant edges and vertices checkbox is selected, edges and vertices that are considered redundant, such as the edges of an imprint on a face, are removed from the imported geometry.
Imported geometric objects can sometimes contain geometric and topological errors, including missing edges and vertices, and entities with invalid sense and invalid tolerance. Errors such as these can be fixed during the import by choosing one of the available options from the Fix errors list:
Choose Automatic (the default) to first check the geometry for topological errors, and if issues are detected attempt to repair.
Choose On to always run the repair operations during import. An initial check of the geometry is not performed in this case.
Choose Off to turn off the repair of topological errors during the import. This can speed up the import if the geometry is known to be correct.
Select the option Simplify curves and surfaces to simplify, within the Absolute import tolerance, the underlying curve and surface manifolds of the imported geometric entities. Importing objects with this option may improve both the performance and reliability of geometric operations on some imported geometry, for example it may help in some cases when Boolean operations on the imported objects fail. Simplification means that the manifolds are converted where possible to analytical form: linear, circular, and elliptical curves; and planar, spherical, cylindrical, conical, and toroidal surfaces. Manifolds that are converted are B-spline curves and surfaces, or certain surfaces generated by operations such as sweeping, revolving, and filleting.
Select the Delete small details checkbox to remove geometric details smaller than the Absolute import tolerance. Details that can be deleted include short edges, sliver faces, small faces, and spikes.
Select (default) the Check imported objects for errors checkbox to check the validity of the imported objects as the last stage of the import. Warning nodes appear with details about the detected problems, if any. Use the Zoom to Selection button next to the Entities list in a warning node to locate the problematic edges or faces. For information on geometry problems that may occur see the Check feature.
Selections
The LiveLink™ interface synchronizes selections for selected elements from the Revit® project. The selections get their names from the element name, type and category. Synchronized selections appear in the Selections from CAD Package table. Click on an entry in the table to see the included objects highlighted in the Graphics window. Selections are available in all applicable selection lists, for example in geometry and mesh operations, or material and physics settings, but do not appear as separate selection nodes in the COMSOL model tree. See the section The Settings Window for Configurations on how to set up the synchronization to include selections for the various elements.
Assigned Attributes
Select the Construction geometry checkbox to make the resulting objects available only in the feature’s geometry sequence. For more information see Construction Geometry in the COMSOL Multiphysics Reference Manual.