Interactive boundary setting module design method, simulation software construction method and device
By designing an interactive boundary setting module, the efficiency and accuracy of domestic finite element simulation software in the setting of boundary conditions is solved, intuitive visual presentation and real-time update capabilities are realized, and user experience and software performance are improved.
Patent Information
- Application Number
- CN202410922783.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-10
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2044-07-10
AI Technical Summary
The existing domestic finite element simulation software has problems such as unfriendly user interface, incomplete functional design and insufficient support for complex models in terms of interactive boundary settings, resulting in low efficiency and accuracy in setting boundary conditions.
Design an interactive boundary setting module to provide intuitive visual presentation by determining the functional architecture, designing a visual framework and differentiated storage mechanism, helping users quickly verify and adjust boundary condition settings.
Improve the accuracy and efficiency of boundary condition settings, improve user interaction experience, and optimize data structure design to support real-time updates under complex interactive logic.
Smart Images

Figure CN118586246B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of finite element simulation, and in particular to a method for designing modules related to interactive geometric modeling, a method for constructing simulation software and a device. Background Art
[0002] In the field of modern engineering simulation, finite element analysis technology is a powerful tool for predicting and solving complex engineering problems. Its accuracy and practicality are highly dependent on accurate and efficient boundary condition settings. Boundary conditions are directly related to the actual constraints and external effects of physical problems, ranging from simple supports and loads to complex heat flow and field distribution. Every detail must be accurate. The traditional method of manually defining boundary conditions through code or dialog box input ID is no longer able to adapt to the simulation needs of modern complex models and multi-dimensional physical fields, and is prone to setting omissions and efficiency bottlenecks.
[0003] Compared with the world's leading commercial finite element software, current domestic software has significant shortcomings in interactive boundary setting, mainly reflected in the unfriendly user interface, incomplete functional design, and insufficient support for complex models. The specific problems can be summarized into three points:
[0004] Complex operation logic and imperfect architecture design: Faced with complicated selection processes and changing condition types, it will be difficult to achieve efficient function development without reasonable software architecture design. The lack of intuitive interface guidance and intelligent assistance makes it difficult for users to understand model requirements and match corresponding boundary conditions, and incorrect configuration and repeated processes occur frequently.
[0005] Lack of visualization of boundary condition settings: There is a lack of visual identification for specific conditions, and failure to fully use graphical technology to show the impact of different conditions on the model, which will make it difficult for users to intuitively judge the correctness and rationality of the settings.
[0006] Inconsistency between data structure and interaction design: The lack of effective mapping between boundary conditions and model topology leads to poor information transmission during the setup process, affecting the overall user experience and software performance.
[0007] In view of this, there is an urgent need to provide an architectural design scheme for the interactive boundary setting module of finite element simulation software to provide intuitive visual presentation for different types of boundary conditions, help users quickly verify and adjust settings, enhance user interaction experience, optimize data structure design, and ensure support for real-time updates under complex interaction logic. Summary of the invention
[0008] In view of this, it is necessary to provide an interactive boundary setting module design method, a simulation software construction method and a device, aiming to solve the technical problems existing in the prior art that the setting efficiency and accuracy are low in the process of boundary condition setting due to the lack of visualization and the incoordination of data structure and interaction.
[0009] In one aspect, the present invention provides an interactive boundary setting module design method, comprising:
[0010] Determine the functional architecture of the interactive boundary setting module based on the boundary condition setting functional requirements;
[0011] A visualization framework is designed based on the boundary condition display logic of the interactive boundary setting module, which is used to visualize the visualization model after the boundary conditions are applied;
[0012] The boundary information of the boundary condition and the visualization model are stored differentially.
[0013] In a possible implementation, the boundary condition setting function requirement includes a displacement boundary condition setting requirement and a load boundary condition setting requirement, and the determining of the functional architecture of the interactive boundary setting module based on the boundary condition setting function requirement includes:
[0014] Obtaining an interactive process of the displacement boundary condition setting requirement and the load boundary condition setting requirement;
[0015] Determine a boundary state diagram and a boundary interaction diagram based on the interaction process;
[0016] A functional architecture of the interactive boundary setting module is determined based on the boundary state diagram and the boundary interaction diagram.
[0017] In a possible implementation, the determining the functional architecture of the interactive boundary setting module based on the boundary state diagram and the boundary interaction diagram includes:
[0018] Determine the interaction logic commonality part and the interaction logic difference part of the interaction process based on the boundary state diagram and the boundary interaction diagram;
[0019] The common part of the interaction logic is designed based on the finite state machine mode, and the different part of the interaction logic is designed based on the strategy mode to generate the functional architecture of the interactive boundary setting module.
[0020] In a possible implementation, the boundary condition display logic of the interactive boundary setting module includes displacement boundary condition display logic and load boundary condition display logic; then the boundary condition display logic design visualization framework based on the interactive boundary setting module includes:
[0021] Determine the common display part and the display difference part of the displacement boundary condition display logic and the load boundary condition display logic;
[0022] The display logic design visualization framework is constructed based on Open CASCADE, the display commonality part and the display difference part.
[0023] In a possible implementation, the boundary condition display logic is:
[0024] Determining a spatial distribution calculation method of the visualization model according to a topological structure type of the boundary condition application area;
[0025] determining a model size of a component geometric model to which boundary conditions are applied, and determining a scaling parameter of the visualization model based on the model size;
[0026] According to the boundary condition type, the visual model is constructed by using the geometric modeling method of Open CASCADE;
[0027] The visualization model is displayed based on the spatial distribution calculation method and the scaling parameter.
[0028] In a possible implementation, the boundary condition types include displacement boundary condition types and load boundary condition types. The displacement boundary condition types include fixed displacement boundary conditions and given displacement boundary conditions. The load boundary condition types include concentrated load boundary conditions, shell edge load boundary conditions and uniformly distributed pressure load boundary conditions.
[0029] In a possible implementation manner, the differentially storing the boundary information of the boundary condition and the visualization model includes:
[0030] Design a direct storage data structure composed of a boundary condition abstract class and different boundary condition specific subclasses based on a combination pattern, wherein the boundary information is stored in the direct storage data structure;
[0031] An indirect storage data structure is designed to associate the topological structure in the geometric model with the boundary condition application area, and the visualization model is stored in the indirect storage data structure.
[0032] On the other hand, the present invention also provides a simulation software construction method, comprising:
[0033] Constructing an interactive boundary setting module based on the design method of the interactive boundary setting module;
[0034] The design method of the interactive boundary setting module is the design method of the interactive boundary setting module described in any one of the possible implementation modes mentioned above.
[0035] On the other hand, the present invention also provides a design device for an interactive boundary setting module, comprising:
[0036] A module functional architecture determination unit, used to determine the functional architecture of the interactive boundary setting module based on the boundary condition setting functional requirements;
[0037] A model visualization unit, used for designing a visualization framework based on the boundary condition display logic of the interactive boundary setting module, and used for visually displaying the visualization model after the boundary conditions are applied;
[0038] The data storage unit is used to differentially store the boundary information of the boundary condition and the visualization model.
[0039] On the other hand, the present invention also provides a simulation software construction device, comprising:
[0040] An interactive boundary setting module construction unit, used for constructing an interactive boundary setting module based on a design method of the interactive boundary setting module;
[0041] The design method of the interactive boundary setting module is the design method of the interactive boundary setting module described in any one of the possible implementation modes mentioned above.
[0042] The beneficial effect of the present invention is that the present invention determines the functional architecture of the interactive boundary setting module based on the boundary condition setting function requirements, and can sort out the complicated selection process and the variable condition types through the functional framework, so that users can quickly understand the model requirements and the boundary conditions that match them, avoid technical problems such as frequent wrong configuration and repeated processes, and improve the accuracy of boundary condition settings.
[0043] Furthermore, a boundary condition display logic design visualization framework based on the interactive boundary setting module realizes intuitive and clear visualization of boundary conditions, helping users to quickly verify and adjust settings and enhance the user's interactive experience.
[0044] In addition, by differentially storing the boundary information and visualization model of boundary conditions, the data structure design is optimized to ensure support for real-time updates under complex interactive logic. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0046] Figure 1A schematic flow chart of an embodiment of the interactive boundary setting module design method provided by the present invention;
[0047] Figure 2 A schematic diagram of an embodiment of a load state diagram provided by the present invention;
[0048] Figure 3 A schematic diagram of an embodiment of a load interaction diagram provided by the present invention;
[0049] Figure 4 A schematic diagram of an embodiment of a displacement state diagram provided by the present invention;
[0050] Figure 5 A schematic diagram of an embodiment of a displacement interaction diagram provided by the present invention;
[0051] Figure 6 A schematic diagram of an embodiment of a class diagram of a boundary condition setting functional architecture design provided by the present invention;
[0052] Figure 7 For the present invention Figure 1 A schematic flow chart of an embodiment of step S102;
[0053] Figure 8 For the present invention Figure 1 The data structure design class diagram of step S103;
[0054] Fig. 9 A schematic structural diagram of an embodiment of the interactive boundary setting module design device provided by the present invention. DETAILED DESCRIPTION
[0055] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0056] It should be understood that the schematic drawings are not drawn to scale. The flowchart used in the present invention shows the operations implemented according to some embodiments of the present invention. It should be understood that the operations of the flowchart can be implemented out of order, and the steps without logical context can be reversed in order or implemented simultaneously. In addition, those skilled in the art, under the guidance of the content of the present invention, can add one or more other operations to the flowchart, and can also remove one or more operations from the flowchart. Some of the block diagrams shown in the accompanying drawings are functional entities, which do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or in one or more hardware modules or integrated circuits, or in different networks and / or processor systems and / or microcontroller systems.
[0057] Reference to an "embodiment" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiment may be included in at least one embodiment of the present invention. The appearance of the phrase in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0058] The present invention provides an interactive boundary setting module design method, a simulation software construction method and a device, which are respectively described below.
[0059] Figure 1 A schematic diagram of an embodiment of the interactive boundary setting module design method provided by the present invention is shown in FIG. Figure 1 As shown, the interactive boundary setting module design method includes:
[0060] S101, determining the functional architecture of the interactive boundary setting module based on the boundary condition setting function requirement;
[0061] S102, designing a visualization framework based on the boundary condition display logic of the interactive boundary setting module, for visually displaying a visualization model after applying boundary conditions;
[0062] S103: Differentiate and store boundary information and visualization models of boundary conditions.
[0063] The interactive boundary setting module design method in the embodiment of the present invention relies on a finite element simulation system with a multi-level architecture. The finite element simulation system with a multi-level architecture includes an interactive interface layer, a functional module layer, a business logic layer, and a data access layer. Then step S101 is implemented based on the functional module layer, step S102 is implemented based on the interactive interface layer, and step S103 is implemented based on the data access layer.
[0064] Compared with the prior art, the embodiment of the present invention determines the functional architecture of the interactive boundary setting module based on the boundary condition setting function requirements, and can sort out the complicated selection process and the variable condition types through the functional framework. This enables users to quickly understand the model requirements and the boundary conditions that match them, avoids technical problems such as frequent misconfiguration and repeated processes, and improves the accuracy of boundary condition settings.
[0065] Furthermore, a boundary condition display logic design visualization framework based on the interactive boundary setting module realizes intuitive and clear visualization of boundary conditions, helping users to quickly verify and adjust settings and enhance the user's interactive experience.
[0066] In addition, by differentially storing the boundary information and visualization model of boundary conditions, the data structure design is optimized to ensure support for real-time updates under complex interactive logic.
[0067] Among them, the boundary condition setting function requirements include displacement boundary condition setting requirements and load boundary condition setting requirements. In order to realize the functional architecture design of the interactive boundary setting module in step S101, it is necessary to analyze the interactive process of the displacement boundary condition setting requirements and the load boundary condition setting requirements, and determine the displacement boundary state diagram, load boundary state diagram, displacement boundary interaction diagram and load boundary interaction diagram based on the interactive process; determine the functional architecture of the interactive boundary setting module based on the displacement boundary state diagram, load boundary state diagram, displacement boundary interaction diagram and load boundary interaction diagram.
[0068] Among them, the displacement state diagram refers to the state diagram that the interactive actions need to follow when setting the displacement boundary conditions, the load state diagram refers to the state diagram that the interactive actions need to follow when setting the load boundary conditions, the displacement interaction diagram refers to the interaction diagram that the interactive actions need to follow when setting the displacement boundary conditions, and the load interaction diagram refers to the interaction diagram that the interactive actions need to follow when setting the load boundary conditions.
[0069] It should be noted that the displacement boundary condition setting requirements include but are not limited to the fixed displacement boundary condition setting requirements and the given displacement boundary condition setting requirements, and the load boundary condition setting requirements include but are not limited to the concentrated load boundary condition setting requirements and the shell edge load boundary condition setting requirements. When determining the interaction process, it is necessary to analyze all the above setting requirements.
[0070] Figure 2A schematic diagram of an embodiment of the load state diagram provided by the present invention shows the states and transitions between states corresponding to several key steps that need to be executed for the load boundary condition setting requirements. In the static finite element modeling and simulation process, there are various types of load boundary conditions, including but not limited to concentrated load boundary conditions and edge load boundary conditions. The edge load boundary conditions can be specifically shell edge load boundary conditions. In order to complete the load boundary condition setting requirement setting operation, it is necessary to go through the "load boundary condition type selection state", "application area selection state" and "load parameter setting state". From Figure 2 It can be noticed that for different types of loads, the "application area selection state" and "load parameter setting state" will be nested under different "load setting states", such as the concentrated load boundary condition corresponds to the "concentrated load setting state" and the shell edge load boundary condition corresponds to the "shell edge load setting state".
[0071] After entering the "Load Boundary Condition Type Selection State", the load type selection dialog box pops up. The system will provide different types of boundary conditions according to the user's selection. The load consists of several major categories at the first level, including but not limited to solid mechanics analysis, thermal analysis, and acoustic analysis. Each major category has different subcategories to choose from at the second level. Taking solid mechanics analysis as an example, its subcategories include but are not limited to concentrated load boundary conditions, shell edge load boundary conditions, uniform pressure load boundary conditions, etc. After the user selects the load boundary conditions to be created and the associated calculation and analysis steps, click the confirmation button in the dialog box to enter the step of selecting the area where the boundary conditions are applied.
[0072] It should be pointed out that the load boundary conditions of the problem to be simulated can be composed of different types and different loads can be applied at different stages. This requires the system to allow multiple calculation and analysis steps to be set for the problem to be analyzed, and to set corresponding load boundary conditions for each analysis step. To this end, the load boundary conditions need to be designed with corresponding attributes to confirm the calculation and analysis step to which they belong.
[0073] After entering the "application area selection state", the load boundary conditions selected by the user are first analyzed and judged to confirm the dimensional characteristics of the applicable parts and the topological structure type of the applicable area. For example, the shell edge load boundary condition can only be applied to the boundary line topological structure of the part whose dimensional characteristics are two-dimensional shells; then, based on the basic method of geometric model operation and display provided by Open CASCADE, the system traverses the component geometric model, identifies the dimensional characteristics of the geometric model to determine whether the geometric model can be used to apply the load boundary conditions selected by the user; if the geometric model meets the dimensional characteristic requirements, the topological structure required for the user-selected load boundary condition is extracted from the model, and highlighted in yellow bold style to prompt the user to select the boundary condition application area in the geometric model. The user can select the highlighted topological structure in the main view by clicking to select or dragging the box to select. When the user selects the topological structure, the system will display its color in red to prompt the user of the selected topological structure. After the user has completed the selection, click the confirmation button in the status bar to enter the "load parameter setting state".
[0074] After entering the "Load Parameter Setting State", the system will make a judgment based on the load boundary condition type selected in the "Load Boundary Condition Type Selection State", and pop up the parameter setting dialog box for this type of load boundary condition for the user to set the relevant parameters. After the user completes the setting, click the Confirm button to complete the load boundary condition setting process.
[0075] Each state is triggered by the Qt signal mechanism. For example, after the "application area selection state" is completed, the "complete" signal will be sent to trigger the state transition; and if the "return" button is clicked in the "load parameter setting state", the "return" signal will be sent to convert back to the "application area selection state". Clicking the "cancel" button in any state will end the load boundary condition setting operation process. It is worth noting that because the "application area selection state" and the "load parameter setting state" are nested in the "load setting state", when the "cancel" button is clicked in these two states, the cancel signal of the "load setting state" will be triggered, thereby entering the "end state".
[0076] Figure 3A schematic diagram of an embodiment of the load interaction diagram provided by the present invention shows the main interaction process that the user needs to go through to set the concentrated load boundary conditions. The interaction process for other types of load boundary conditions is similar. The user first interacts with the boundary setting function manager class BCActionsManager and selects "Create load boundary conditions" in the visual interface. Subsequently, based on the selected load type, BCActionsManager calls the "Start" method of the boundary creation control class BCBaseGenerationControl, starts its corresponding finite state machine, and enters the boundary condition type selection state class BCBaseTypeSelectionState. After entering this state, the system displays the load creation dialog box QmyGenerateLoadDialog for the user to select the type of load boundary condition to be created.
[0077] In this example, the user selects concentrated load in QmyGenerateLoadDialog and clicks OK. QmyGenerateLoadDialog determines the additional state information based on the selected load type and sets it in BCBaseGenerationControl. Based on the additional state information, BCBaseGenerationControl creates another finite state machine to form a nested finite state machine and enters the concentrated load setting state ConcentratedForceLoadSettingState. Figure 2 The nested state association of "Concentrated Load Setting State" in the Figure 2 As shown, in this nested state, it will automatically enter the "application area selection state", which corresponds to the concentrated load boundary condition, that is, the point structure selection state class VertexSelectionState. At this time, the system traverses the topological structure in the geometric model of the component and extracts the point topological structure for yellow highlighting, because concentrated loads can only be set on point topological structures.
[0078] Then, the user selects the point topology as the area where the concentrated load boundary condition is to be applied, clicks OK and enters the boundary condition editing state class BCBaseEditState. At this time, the system pops up the concentrated load editing dialog box QmyEditConcentratedForceLoadDialog for the user to set the concentrated load boundary condition parameters, such as load direction and load value.
[0079] After completing the parameter settings and clicking OK, QmyEditConcentratedForceLoadDialog will interact with the concentrated load generator class ConcentratedForceLoadGenerator, generate the concentrated load boundary condition ConcentratedForceLoad based on the concentrated load boundary condition information parameters set by the user, and add it to the system's data model. At this point, the creation of the concentrated load boundary condition is completed.
[0080] Among them, the boundary conditions include constraint boundary conditions and displacement boundary conditions. Figure 4 The boundary state diagram provided by the present invention shows the states and transitions between the states corresponding to the several key steps that need to be executed in the interactive displacement boundary condition setting function. Figure 2 By comparing the load state diagrams, it can be found that the general structures of the two are basically the same.
[0081] Figure 5 This is a schematic diagram of an embodiment of the boundary interaction diagram provided by the present invention, showing the main interaction process that a user needs to go through to set a fixed displacement boundary condition. The interaction process of other types of displacement boundary conditions is similar. Figure 4 As mentioned above, displacement boundary conditions and load boundary conditions have roughly the same structure in the state diagram of the interactive setting function. Therefore, the interactive diagram of the interactive displacement boundary condition setting represented by the fixed displacement boundary condition setting should also be similar to the interactive diagram of the interactive load boundary condition setting represented by the concentrated load boundary condition setting, such as Figure 5 and Figure 3 As shown. Both contain the same classes such as BCBaseGenerationControl, BCBaseTypeSelectionState, BCBaseEditState, etc. At the same time, both also contain different specific implementation classes, such as:
[0082] exist Figure 5 In , the finite state machine enters the full structure selection state class AllSelectionState, providing all topological structures highlighted for users to select; Figure 3 In the finite state machine, the point structure selection state class VertexSelectionState is entered, and only point topology structures are provided for users to select. This is because the fixed displacement boundary condition can be applied to any topological structure, while the concentrated load boundary condition can only be applied to the point topological structure of the geometric model. Therefore, during the displacement boundary condition setting process, when entering the "application area selection state", the system traverses the component geometry model, extracts the point and line topological structures from it, and highlights them in yellow bold style to prompt users to select the displacement boundary condition application area in the geometric model.
[0083] Figure 5 The parameters required to be set in the fixed displacement editing dialog box QmyEditFixedDisplacementDialog are the same as Figure 3 The parameters that need to be set in the concentrated load editing dialog box QmyEditConcentratedForceLoadDialog are different. In QmyEditFixedDisplacementDialog, you need to select the direction of the fixed displacement boundary condition to be applied; while in QmyEditConcentratedForceLoadDialog, you need to select not only the direction of the concentrated load boundary condition to be applied, but also enter the load value in the relevant direction. Based on the parameters set by the two, the system will call FixedDisplacementGenerator and ConcentratedForceLoadGenerator to generate the fixed displacement boundary condition FixedDisplacement and the concentrated load boundary condition ConcentratedForceLoad respectively, which have different properties and parameters.
[0084] Faced with complicated selection processes and changing condition types, it will be difficult to achieve efficient function development without reasonable architecture design. Therefore, based on the execution steps of the interactive displacement boundary condition setting function and the interactive load boundary condition setting function, there are commonalities and differences between the two. In order to improve the rationality of the functional architecture, in some embodiments of the present invention, the functional architecture of the interactive boundary setting module is determined based on the boundary state diagram, the load state diagram, the boundary interaction diagram and the load interaction diagram, including:
[0085] Determine the common interaction logic part and the difference interaction logic part of the interaction process based on the boundary state diagram, load state diagram, boundary interaction diagram and load interaction diagram;
[0086] The common part of the interaction logic is designed based on the finite state machine pattern, and the different part of the interaction logic is designed based on the strategy pattern to generate the functional architecture of the interactive boundary setting module.
[0087] The embodiments of the present invention achieve the decoupling of various boundary condition functions and enhance the expansibility and flexibility of the interactive boundary setting module design method.
[0088] It should be noted that when determining the common interaction logic parts and the different interaction logic parts of the interaction process, it is necessary to analyze the interaction processes of multiple boundary conditions such as fixed displacement boundary conditions, given displacement boundary conditions, concentrated load boundary conditions, shell edge load boundary conditions, etc., and extract the common interaction logic parts and the different interaction logic parts of these interaction processes.
[0089] Specifically, for example, in the step of selecting the boundary condition application area in the "application area selection state", the load boundary condition application area requires the system to analyze and judge the dimensional characteristics of the geometric model and the specific type of the load boundary condition, so as to confirm the topological structure that can be selected for highlighting; and the system judgment process of the boundary condition application area is relatively simple. Therefore, targeted design is required in the development of the execution steps of load boundary condition application. Based on the above-mentioned common abstract parts and the specific implementation parts with differences, the class diagram design of the interactive boundary condition setting functional architecture can be carried out as follows Figure 6 shown.
[0090] Design boundary creation control class BCBaseGenerationControl, as the core class for boundary condition creation, to manage the state setting of the finite state machine and the state transition trigger condition setting. It forms an aggregation relationship with each state class to achieve Figure 2 The load state diagram and Figure 4 Displacement state diagram.
[0091] In this functional architecture design, the two most basic abstract state classes are the boundary creation base state class BCBaseGenerationState and the boundary setting base state class BCBaseSettingState, where:
[0092] The boundary creation base state class BCBaseGenerationState is Figure 2 and Figure 4 The parent class of various specific states in , which provides common properties and abstract interfaces of each state class. Based on BCBaseGenerationState, you can design:
[0093] Boundary condition type selection state class BCBaseTypeSelectionState corresponds to Figure 2 and Figure 4"Boundary condition type selection state" in it. This class directly forms an aggregation relationship with BCBaseGenerationControl, and is the first state entered by the finite state machine from the initial state after executing the start operation. BCBaseTypeSelectionState is used to manage the interactive dialog box for creating boundary conditions. For different boundary conditions, the dialog box needs to have different button arrangements and operation functions. For example, in the displacement boundary creation dialog box, displacement boundary conditions such as fixed displacement boundary conditions and given displacement boundary conditions are provided, while in the load boundary creation dialog box, concentrated load boundary conditions, shell edge load boundary conditions and other load boundary conditions are provided. Options. Therefore, based on QmyGenerateBCBaseDialog, the displacement creation dialog class QmyGenerateDisplacementDialog and the load creation dialog class QmyGenerateLoadDialog can be designed to respectively implement the different button arrangements and operation functions in the displacement boundary condition creation dialog box and the load boundary condition creation dialog box;
[0094] Boundary region selection basic state class BCBasicRegionSelectionState corresponds to Figure 2 and Figure 4 "Apply region selection state" in. Although BCBasicRegionSelectionState inherits from the abstract class BCBaseGenerationState and implements abstract methods such as concrete_state_confirm(), it is still an abstract class that provides common methods and operation interfaces, and has not implemented all abstract methods. This class provides highlight settings for topological structures in geometric models to clarify the types of topological structures that users can select in the current "apply region selection state". Since the selectable topological structures of geometric models are different for different boundary conditions, it is necessary to design subclasses with different implementation methods to meet the requirements of optional regions for different topological structures. For example, the full structure selection state class AllSelectionState inherited from BCBasicRegionSelectionState is designed to realize the highlighting of the full topological structure of points, lines, and surfaces, and to clarify that all types of topological structures can be used as applicable regions for users to select. For another example, the point structure selection state class VertexSelectionState inherited from BCBasicRegionSelectionState is designed to realize the highlighting of point topological structures, and to clarify that only point topological structures can be used as applicable regions for users to select;
[0095] Boundary parameter editing state class BCBaseEditState corresponds to Figure 2 and Figure 4The "parameter setting state" in the dialog box. This class is responsible for providing a dialog box for users to set the parameters of boundary conditions, so this class forms a combination relationship with the boundary editing basic dialog box class QmyEditBasicBCDialog. As an abstract class, QmyEditBasicBCDialog provides common methods such as dialog content initialization update_basic_info_and_widgets() on the one hand, and provides abstract interfaces such as generate_bc() for generating boundary conditions on the other hand. Based on QmyEditBasicBCDialog, the load boundary condition editing dialog box class QmyEditLoadDialog and the displacement condition editing dialog box class QmyEditDisplacementDialog can be designed respectively. These two abstract classes further provide common methods such as add_data_to_model() for adding the created boundary conditions into the data model. Based on QmyEditLoadDialog, the dialog box class corresponding to the specific load boundary condition can be designed, such as the concentrated load editing dialog box class QmyEditConcentratedForceLoadDialog. This class clarifies the UI content of the parameter setting dialog box corresponding to the specific load boundary condition, and implements the abstract interfaces such as generate_bc() in the base class. Based on QmyEditDisplacementDialog, a dialog class corresponding to a specific displacement boundary condition can be designed, such as the fixed displacement editing dialog class QmyEditFixedDisplacementDialog. This class clarifies the UI content of the parameter setting dialog box corresponding to the specific displacement boundary condition, and implements abstract interfaces such as generate_bc() in the base class. In order to implement the boundary condition generation operation, it is also necessary to design a boundary condition basic generator class BCBaseGenerator to form a combination relationship with QmyEditBasicBCDialog. As an abstract class, BCBaseGenerator provides abstract interfaces such as get_bc_info() for obtaining boundary condition information. Subclasses inherited from BCBaseGenerator are designed to implement the methods required to create specific load boundary conditions and displacement boundary conditions. For example, the concentrated load boundary generator class ConcentratedForceLoadGenerator and the fixed displacement boundary generator class FixedDisplacementGenerator respectively design corresponding information acquisition methods for the parameter information required for their corresponding boundary conditions, and finally integrate the information into the get_bc_info() abstract method of the base class, thereby implementing the creation method of the corresponding boundary conditions.The above-mentioned specific generator class needs to form a combination relationship with the specific boundary editing dialog class, such as ConcentratedForceLoadGenerator and QmyEditConcentratedForceLoadDialog form a combination relationship, and FixedDisplacementGenerator and QmyEditFixedDisplacementDialog form a combination relationship;.
[0096] The boundary setting base state class BCBaseSettingState is Figure 2 and Figure 4 The base class for various "boundary setting states" in, for example Figure 2 "Concentrated load setting status" in Figure 4"Fixed displacement setting state" in . As mentioned above, this state is a nested state, which includes "application region selection state" and "boundary parameter setting state". In the functional architecture class diagram, at the abstract level, BCBaseSettingState forms a combination relationship with BCBasicRegionSelectionState and BCBaseEditState respectively. When entering the specific subclass of the nested state BCBaseSettingState, it is equivalent to opening a nested finite state machine under the already opened finite state machine to execute the specific subclass operations of BCBasicRegionSelectionState and BCBaseEditState in sequence. For different specific boundary conditions, a specific boundary condition setting state subclass inherited from BCBaseSettingState can be designed. For example, a concentrated load setting state class ConcentratedForceLoadSettingState can be designed. If entering this nested state, the system will highlight the point topology structure when applying region selection, and the concentrated load boundary dialog box will pop up when setting the load boundary condition parameters. Therefore, ConcentratedForceLoadSettingState forms a combination relationship with VertexSelectionState and QmyEditConcentratedForceLoadDialog respectively. Similarly, a fixed displacement setting state class FixedDisplacementSettingState can also be designed. If this nested state is entered, the system will highlight the full topological structure of points, lines, and surfaces when applying area selection, and the fixed displacement boundary dialog box will pop up when setting the displacement boundary condition parameters. Therefore, FixedDisplacementSettingState forms a combination relationship with AllSelectionState and QmyEditFixedDisplacementDialog respectively.
[0097] At this point, BCBaseGenerationControl forms an aggregation relationship with the specific subclasses of BCBaseGenerationState and BCBaseSettingState. The functional architecture design composed of them can realize the interaction logic listed in the interaction diagram and state diagram of the above boundary condition setting function.
[0098] The interactive boundary condition setting function architecture designed in the embodiment of the present invention, at the software development level, uses common abstract parts to effectively reduce the development difficulty of the module function, such as a large number of common parts in the boundary condition setting function and the load boundary condition setting function only need to be developed once; the specific functions are decoupled to effectively promote the independent and efficient development of related specific functions, such as when developing specific functions of different subcategories in different major categories in the load boundary condition setting function, there is no need to pay attention to the overall architecture content and interaction logic, only the specific execution function needs to be designed for the "application area selection state" to match the corresponding topological structure according to the geometric model dimensional characteristics and load type judgment, and the specific parameter setting dialog box needs to be designed for the "parameter setting state". At the software usage level, the boundary condition setting function developed based on this design decomposes complex interactive operations into independent steps, and carries out targeted design for the user's interactive experience in each step to improve the efficiency and accuracy of the user's boundary condition setting operation.
[0099] After completing the creation and setting of boundary conditions, they need to be visualized and displayed, so a corresponding display mechanism needs to be designed. In a specific embodiment of the present invention, the boundary condition display logic of the interactive boundary setting module includes displacement boundary condition display logic and load boundary condition display logic, and step S102 includes:
[0100] Determine the common display part and the display difference part of the displacement boundary condition display logic and the load boundary condition display logic;
[0101] A visualization framework for display logic design is constructed based on Open CASCADE, display common parts and display difference parts.
[0102] The embodiment of the present invention can achieve the decoupling of the displacement boundary condition display logic and the load boundary condition display logic by determining the display commonality part and the display difference part, and further improve the flexibility and scalability of the interactive boundary setting module design method.
[0103] Among them, the displacement boundary condition types include fixed displacement boundary conditions and given displacement boundary conditions, and the load boundary condition types include concentrated load boundary conditions, shell edge load boundary conditions and uniformly distributed pressure load boundary conditions.
[0104] It should be understood that the logic of displaying displacement boundary conditions is basically the same as that of displaying load boundary conditions.
[0105] In a specific embodiment of the present invention, Figure 7 As shown, the boundary condition display logic is:
[0106] S701, determining a spatial distribution calculation method of a visualization model according to a topological structure type of a region where boundary conditions are applied;
[0107] S702, determining a model size of a component geometric model to which boundary conditions are applied, and determining a scaling parameter of a visualization model based on the model size;
[0108] S703. According to the boundary condition type, a visual model is constructed using the geometric modeling method of Open CASCADE;
[0109] S704: Display the visualization model based on the spatial distribution calculation method and the scaling parameters.
[0110] Among them, in step S701, if the topological structure is a point, it only needs to be displayed at this point; if the topological structure is a line or a surface, it is necessary to call the system's built-in method to calculate a point set with a reasonable spatial distribution, display the relevant boundary condition objects with a relatively uniform spatial distribution, and record the calculated spatial coordinates of the point set in a list.
[0111] Then, in step S702, the determined scaling parameters can be used to scale the visualization model accordingly based on the model size. The determination of the scaling parameters can ensure that when the components to be analyzed have large geometric size differences, boundary conditions of appropriate sizes are displayed on components of different sizes, so that users can use appropriate visualization effects to determine the accuracy of the applied boundary conditions.
[0112] For example, the visualization model refers to the geometric shape of the arrow style used to represent the applied boundary conditions, and the component geometry model refers to the geometry model of each component in the geometry model built by the geometry modeling module, such as a cuboid and a cylinder. When multiple component geometry models of different sizes are included, the visualization model can be scaled based on the scaling parameter to match the visualization model with the component geometry model to improve the visualization effect.
[0113] It should be noted that the model size is calculated automatically by the system after the component creation operation is completed, and the relevant results are managed by the component as component attributes. The calculation process requires calling the brepbndlib_Add() and Bnd_Box() methods provided by Open CASCADE to build a bounding rectangle for the component to calculate the maximum distance between its diagonal vertices, which is used as the model size.
[0114] Then, in step S703, the system constructs a visualization model of the boundary condition using the geometric modeling method of Open CASCADE according to the boundary condition type, and gives the visualization model different visualization effects based on relevant parameter settings. Finally, the system displays the visualization model.
[0115] Under the above-mentioned boundary condition visualization framework based on Open CASCADE, the difference between the displacement boundary condition display and the load boundary condition display can still be summarized, which is mainly reflected in step S703, and targeted design is required:
[0116] Displacement boundary conditions have their own special display logic. Taking fixed displacement boundary conditions as an example, the geometric features of the visualization model of this type of boundary conditions are first determined to be conical arrows built based on the Open CASCADE geometric modeling function. The arrow has four attributes that need to be confirmed, namely coordinates, size, direction, and color. The coordinates are provided by the list of point set spatial coordinates obtained in S701, the size is provided by the approximate geometric dimensions of the component obtained in S702, and the direction and color selection are related to the parameter settings of the boundary conditions in S703. The user needs to set a specific constraint direction through the displacement boundary condition, and the constraint direction will be used as the arrow direction of the boundary condition display object; in addition, the fixed displacement boundary condition contains displacement constraints in three directions and rotation constraints in three directions. The displacement constraints are represented by yellow single arrows, and the rotation constraints are represented by green double arrows. At this point, all the attributes required for the conical arrow in the visualization model are confirmed, and then the geometric model of the corresponding display object can be constructed by calling the relevant basic methods of OpenCASCADE and displayed in the main view.
[0117] The load boundary conditions also have their own special display logic. Taking the shell edge load boundary condition as an example, the geometric features of the visualization model of this type of boundary condition are first determined to be arrows with solid lines built based on the Open CASCADE geometric modeling function. The arrow has four attributes that need to be confirmed, namely coordinates, size, direction, and color. The coordinates are provided by the list of point set spatial coordinates obtained in S701, the size (including the size of the arrow and the length of the solid line) is provided by the approximate geometric dimensions of the component obtained in S702, the color is set to red, and the direction and selection are related to the parameter setting of the boundary condition in S703. The user needs to select the load application method when setting the parameters of the shell edge load boundary condition, including but not limited to normal load, tangential load, moment load, etc. Selecting different load application methods will cause the load direction to be distributed in different ways: if the normal load is selected, the system will calculate the normal of each point on the shell edge curve and use it as the reference direction of the arrow in the visualization model; if the tangential load is selected, the system will calculate the tangent of each point on the shell edge curve and use it as the reference direction of the arrow in the visualization model. After determining the reference direction, the system will finally confirm the direction of the load according to the positive and negative signs of the load values entered by the user: if the normal load is selected and the value is positive, all arrows in the visualization model of the shell edge load boundary condition point to the outside of the shell component along the normal direction of each point; if the normal load is selected and the value is negative, all arrows in the visualization model of the shell edge load boundary condition point to the inside of the shell component along the normal direction of each point.
[0118] Therefore, in the actual development process, it is necessary to design and develop different visualization methods according to the different requirements of specific boundary conditions. Compared with the prior art, the boundary condition visualization framework based on Open CASCADE provided by the present invention effectively reduces the development difficulty of the module function by using the common abstract part at the software development level, such as Figure 7 The functions corresponding to the entire process of step S701 and step S702 and part of the process in step S703 only need to be developed once; the specific functions are decoupled to effectively promote the independent and efficient development of related specific functions, such as Figure 7 The difference between the displacement boundary condition display logic and the load boundary condition display logic in step S703 requires independent development for each specific boundary condition, and in this process, it is not necessary to pay attention to the overall architecture content and interaction logic. At the software usage level, the visualization framework can clearly show the difference between the displacement boundary condition and the load boundary condition, and at the same time visually and qualitatively display the parameter settings of the relevant conditions, so that users can conduct visual inspections after completing the creation of the boundary conditions, so as to improve the efficiency and accuracy of users' boundary condition setting operations.
[0119] In actual simulation analysis, more complex boundary condition setting problems will be encountered: on the one hand, under complex working conditions, the boundary conditions involved may be large in number and of various types; on the other hand, in the case of multiple analysis steps, the boundary conditions in each different analysis step will be different. In the boundary setting module, compared with the parameter numerical information of the boundary conditions, the boundary condition visualization model is a geometric model based on Open CASCADE, which has higher storage capacity requirements. This type of visualization model can enhance the user's interactive experience by designing the display effect of the boundary conditions. However, it should be noted that it is the numerical information parameters of the boundary conditions, not the visualization model of the boundary conditions, that actually participate in the finite element simulation calculation. Therefore, in order to optimize the storage space, the embodiments of the present invention respectively design differentiated data structures and storage methods for the numerical information parameters and visualization models of the boundary conditions.
[0120] Specifically, step S103 includes:
[0121] Based on the combination mode, a direct storage data structure consisting of a boundary condition abstract class and different boundary condition specific subclasses is designed, and the boundary information is stored in the direct storage data structure;
[0122] An indirect storage data structure is designed to associate the topological structure in the geometric model with the area where the boundary conditions are applied. The visualization model is stored in the indirect storage data structure.
[0123] The above two data structures are designed based on class diagrams. Specifically, Figure 8 The class diagram for the data structure design of the embodiment of the present invention specifically includes:
[0124] Based on the combination pattern, the abstract model node class BaseObject and the abstract container class BaseContainerObject are designed to form a tree-like hierarchical data structure, where:
[0125] The abstract model node class BaseObject provides the most basic abstract base class in the current data structure design. In terms of attributes, it has data features such as uid and node_type, and in terms of methods, it provides model node management methods such as add_child() and remove_child().
[0126] The abstract container class BaseContainerObject inherits from the abstract model node class BaseObject, so it has all the properties and methods of the abstract model. In addition, BaseContainerObject also provides additional methods for managing child node objects to achieve real-time maintenance of its child node objects and instant update of the name attribute when the number of child node objects changes.
[0127] Based on BaseObject, the basic abstract class BCBaseClass of boundary conditions is designed. This class is the core data entity class in the boundary setting module. On the one hand, it is responsible for managing the attributes and data related to the boundary conditions, and forms an aggregation relationship with the basic basic information class BaseBasicInfo and the boundary condition basic strategy information class BCBaseStgInfo; on the other hand, it has common methods, including but not limited to obtaining the spatial coordinates of the display object, obtaining the geometric dimensions of the display object, etc., providing an abstract interface for the boundary condition subclass.
[0128] Based on BCBaseClass, the load boundary condition abstract class Load and the displacement boundary condition abstract class BoundaryCondition are designed respectively. Based on BaseContainerObject, the displacement boundary condition container class BoundaryConditions and the load boundary condition container class Loads are designed respectively to manage the model node data BoundaryCondition and Load in the hierarchical structure.
[0129] Different specific boundary condition subclasses can implement their required exclusive methods based on inheriting the corresponding abstract class (BoundaryCondition or Load). For example, the fixed displacement boundary condition FixedDisplacement needs to display a conical arrow to indicate the constraint direction according to the parameters set by the user; the shell edge load boundary condition ShellEdgeLoad needs to calculate the tangent and normal directions of each point on the shell boundary line, and draw a complete arrow in the corresponding direction to indicate the load direction according to the load method selected by the user.
[0130] In order to construct a specific boundary condition object, it is necessary to obtain the user's boundary condition interaction setting parameter information. To this end, based on BaseBasicInfo, the displacement boundary information class DisplacementBasicInfo, the load boundary information class LoadBasicInfo and other subclasses are designed to record the parameter numerical information related to the boundary conditions; based on BCBaseStgInfo, the fixed displacement strategy information class FixedDisplacementStgInfo, the concentrated load strategy information class ConcentratedForceLoadStgInfo and other subclasses are designed to record the parameter strategy information related to the boundary conditions. Based on such a design, an aggregate association between a specific boundary condition class and related information can be formed, for example, the fixed displacement boundary class FixedDisplacement forms an aggregate relationship with the displacement boundary information class DisplacementBasicInfo and the fixed displacement strategy information class FixedDisplacementStgInfo.
[0131] Based on the above data structure design, the direct storage of the numerical information of the boundary condition parameters can be realized. In order to realize the indirect storage of the visual model of the boundary condition, the following data structure and storage method design is required:
[0132] The geometry object information class ShapeInfo is designed to store the data related to the geometry model of the component. This class has the attribute entities for managing the entity information class EntityInfo. EntityInfo stores the topological structures such as points, lines, and surfaces in the geometry model of the component. There is an aggregation relationship between ShapeInfo and EntityInfo.
[0133] The application region class SelectionRegion is designed to record the information of the boundary condition application region. When the user creates a boundary condition, it is necessary to select the region where the boundary condition is to be applied. This region is reflected in the data structure as the topological structure of the geometric model, corresponding to the EntityInfo in the geometric object information ShapeInfo of the component. The EntityInfo object corresponding to the topological structure selected by the user will be recorded in the SelectionRegion object, and the two form an aggregation relationship.
[0134] In the basic information class BaseBasicInfo, the location attribute is designed to correspond to a list of SelectionRegion, which is used to manage the object information of the boundary condition application area, and an aggregation relationship is formed between BaseBasicInfo and SelectionRegion. So far, through the design of the data structure, the association of the three data entity classes of the topological structure in the geometric model, the boundary condition application area and the boundary condition object is completed.
[0135] With the above data structure support, in order to correctly display the visual model of boundary conditions in the boundary setting module, the following design is required:
[0136] When it is necessary to display the visualization model of the boundary condition, the system calls the get_sizes_and_locs_for_arrow_visual() method of BCBaseClass, and determines the topological structure imposed by the boundary condition by traversing the topological structure information object EntityInfo corresponding to the SelectionRegion in the boundary condition parameter numerical information corresponding to BCBaseClass. Then the system calculates the distribution mode of these topological structures to obtain the spatial coordinate values of the distribution points of the arrows in the boundary condition visualization model. Subsequently, the specific subclasses of the displacement boundary condition BoundaryCondition and the load boundary condition Load inherited from the boundary condition basic abstract object BCBaseClass calculate the direction of the arrow in the boundary condition visualization model according to the parameters set by the user. Finally, the geometric model of the arrow in the boundary condition visualization model is constructed by combining the spatial coordinates of the arrow distribution point and the arrow direction using the OpenCASCADE related geometric modeling method, and provided to the system for visualization of the boundary condition.
[0137] In the above process, there is no direct storage of the boundary condition visualization model. Instead, the visualization model is generated in real time and efficiently based on the numerical information of the boundary conditions corresponding to the current calculation and analysis step when needed. Its main function is to use a set of arrows with clear directions and certain distribution characteristics to explicitly show the characteristics of the applied boundary conditions to the user when the user performs the interactive boundary condition setting function, thereby helping the user to confirm the correctness of the applied boundary conditions. This visualization model does not affect the modeling function and simulation calculation of the system, and only needs to be displayed in the boundary condition setting module. Therefore, there is no need to actually store the object to increase the storage burden of additional geometric model elements.
[0138] On the other hand, an embodiment of the present invention further provides a simulation software construction method, comprising:
[0139] Constructing an interactive boundary setting module based on the design method of the interactive boundary setting module;
[0140] The design method of the interactive boundary setting module is the design method of the interactive boundary setting module in any one of the above embodiments.
[0141] It should be noted that the simulation software construction method also includes constructing other functional modules in the finite element analysis process such as geometric modeling modules and meshing modules based on other methods, which will not be described one by one here.
[0142] In order to better implement the design method of the interactive boundary setting module in the embodiment of the present invention, based on the design method of the interactive boundary setting module, the embodiment of the present invention also provides a design device of the interactive boundary setting module, such as Fig. 9 As shown, the design device 900 of the interactive boundary setting module includes:
[0143] A module functional architecture determining unit 901 is used to determine the functional architecture of the interactive boundary setting module based on the boundary condition setting function requirement;
[0144] A model visualization unit 902, used for designing a visualization framework based on the boundary condition display logic of the interactive boundary setting module, and for visually displaying a visualization model after applying boundary conditions;
[0145] The data storage unit 903 is used to differentially store the boundary information and the visualization model of the boundary condition.
[0146] The design device 900 of the interactive boundary setting module provided in the above embodiment can implement the technical solution described in the design method embodiment of the above interactive boundary setting module. The specific implementation principles of the above modules or units can refer to the corresponding contents in the design method embodiment of the above interactive boundary setting module, which will not be repeated here.
[0147] In order to better implement the simulation software construction method in the embodiment of the present invention, based on the simulation software construction method, the embodiment of the present invention also provides a simulation software construction device, and the simulation software construction device includes:
[0148] An interactive boundary setting module construction unit, used for constructing an interactive boundary setting module based on a design method of the interactive boundary setting module;
[0149] The design method of the interactive boundary setting module is the design method of the interactive boundary setting module in any one of the above embodiments.
[0150] Accordingly, an embodiment of the present invention also provides a computer-readable storage medium, which is used to store computer-readable programs or instructions. When the program or instructions are executed by a processor, it can implement the interactive geometric modeling related module design method provided in the above-mentioned method embodiments, and / or the steps or functions in the simulation software construction method.
[0151] Those skilled in the art will appreciate that all or part of the processes of the above-mentioned embodiments can be implemented by instructing related hardware (such as a processor, a controller, etc.) through a computer program, and the computer program can be stored in a computer-readable storage medium, wherein the computer-readable storage medium is a disk, an optical disk, a read-only storage memory, or a random access memory, etc.
[0152] The above is a detailed introduction to an interactive boundary setting module design method, simulation software construction method and device provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for technical personnel in this field, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. An interactive boundary setting module design method, characterized in that: include: Determine the functional architecture of the interactive boundary setting module based on the boundary condition setting functional requirements; A visualization framework is designed based on the boundary condition display logic of the interactive boundary setting module, which is used to visualize the visualization model after the boundary conditions are applied; Differentiated storage of boundary information of the boundary condition and the visualization model; The boundary condition setting function requirements include displacement boundary condition setting requirements and load boundary condition setting requirements, and the functional architecture of the interactive boundary setting module is determined based on the boundary condition setting function requirements, including: Obtaining an interactive process of the displacement boundary condition setting requirement and the load boundary condition setting requirement; Determine a boundary state diagram and a boundary interaction diagram based on the interaction process; determining a functional architecture of the interactive boundary setting module based on the boundary state diagram and the boundary interaction diagram; The determining of the functional architecture of the interactive boundary setting module based on the boundary state diagram and the boundary interaction diagram comprises: Determine the interaction logic commonality part and the interaction logic difference part of the interaction process based on the boundary state diagram and the boundary interaction diagram; Designing the common part of the interaction logic based on the finite state machine mode, and designing the different part of the interaction logic based on the strategy mode, so as to generate the functional architecture of the interactive boundary setting module; The boundary condition display logic of the interactive boundary setting module includes displacement boundary condition display logic and load boundary condition display logic; then the boundary condition display logic design visualization framework based on the interactive boundary setting module includes: Determine the common display part and the display difference part of the displacement boundary condition display logic and the load boundary condition display logic; Building the display logic design visualization framework based on Open CASCADE, the display commonality part and the display difference part; The boundary condition display logic is: Determining a spatial distribution calculation method of the visualization model according to a topological structure type of the boundary condition application area; determining a model size of a component geometric model to which boundary conditions are applied, and determining a scaling parameter of the visualization model based on the model size; According to the boundary condition type, the visual model is constructed by using the geometric modeling method of Open CASCADE; The visualization model is displayed based on the spatial distribution calculation method and the scaling parameter.
2. The interactive boundary setting module design method according to claim 1, characterized in that: The boundary condition types include displacement boundary condition types and load boundary condition types. The displacement boundary condition types include fixed displacement boundary conditions and given displacement boundary conditions. The load boundary condition types include concentrated load boundary conditions, shell edge load boundary conditions and uniformly distributed pressure load boundary conditions.
3. The interactive boundary setting module design method according to claim 1, characterized in that: The step of differentially storing the boundary information of the boundary condition and the visualization model comprises: Design a direct storage data structure composed of a boundary condition abstract class and different boundary condition specific subclasses based on a combination pattern, wherein the boundary information is stored in the direct storage data structure; An indirect storage data structure is designed to associate the topological structure in the geometric model with the boundary condition application area, and the visualization model is stored in the indirect storage data structure.
4. A simulation software construction method, characterized in that: include: Constructing an interactive boundary setting module based on the design method of the interactive boundary setting module; Wherein, the design method of the interactive boundary setting module is the design method of the interactive boundary setting module described in any one of claims 1-3.
5. A design device for an interactive boundary setting module, characterized in that: include: A module functional architecture determination unit, used to determine the functional architecture of the interactive boundary setting module based on the boundary condition setting functional requirements; A model visualization unit, used for designing a visualization framework based on the boundary condition display logic of the interactive boundary setting module, and used for visually displaying the visualization model after the boundary conditions are applied; A data storage unit, used for differentially storing the boundary information of the boundary condition and the visualization model; The boundary condition setting function requirements include displacement boundary condition setting requirements and load boundary condition setting requirements, and the functional architecture of the interactive boundary setting module is determined based on the boundary condition setting function requirements, including: Obtaining an interactive process of the displacement boundary condition setting requirement and the load boundary condition setting requirement; Determine a boundary state diagram and a boundary interaction diagram based on the interaction process; determining a functional architecture of the interactive boundary setting module based on the boundary state diagram and the boundary interaction diagram; The determining of the functional architecture of the interactive boundary setting module based on the boundary state diagram and the boundary interaction diagram comprises: Determine the interaction logic commonality part and the interaction logic difference part of the interaction process based on the boundary state diagram and the boundary interaction diagram; Designing the common part of the interaction logic based on the finite state machine mode, and designing the different part of the interaction logic based on the strategy mode, so as to generate the functional architecture of the interactive boundary setting module; The boundary condition display logic of the interactive boundary setting module includes displacement boundary condition display logic and load boundary condition display logic; then the boundary condition display logic design visualization framework based on the interactive boundary setting module includes: Determine the common display part and the display difference part of the displacement boundary condition display logic and the load boundary condition display logic; Building the display logic design visualization framework based on Open CASCADE, the display commonality part and the display difference part; The boundary condition display logic is: Determining a spatial distribution calculation method of the visualization model according to a topological structure type of the boundary condition application area; determining a model size of a component geometric model to which boundary conditions are applied, and determining a scaling parameter of the visualization model based on the model size; According to the boundary condition type, the visual model is constructed by using the geometric modeling method of Open CASCADE; The visualization model is displayed based on the spatial distribution calculation method and the scaling parameter.
6. A simulation software construction device, characterized in that: include: An interactive boundary setting module construction unit, used for constructing an interactive boundary setting module based on a design method of the interactive boundary setting module; Wherein, the design method of the interactive boundary setting module is the design method of the interactive boundary setting module described in any one of claims 1-3.
Citation Information
Patent Citations
Visual modeling method for distributed simulation platform
CN105677446A
DCS system control logic automatic test method
CN118226821A