The demand for simulation of physical systems of all types continues to grow, especially in areas of product development and design. Because physical production of prototypes for testing is time-consuming and often expensive, simulation, particularly simulation performed by computer systems, can provide a valuable tool that streamlines research and development to a narrow set of possible solutions to a problem prior to expensive physical testing.
The simulation of physical systems often employs a mesh which is used in a discretization method (e.g. finite volume method) to provide outputs for the simulation. A mesh includes elements that are typically simple shapes such as tetrahedrons, hexahedrons, prisms, and other volumetric (three dimensional—3D) shapes. These simple shapes have faces, edges, and vertices. A mesh includes a collection of these elements, which can be referred to as mesh elements, and a mathematical description of the relationship between the nodes, edges, and faces of the mesh elements. In a numerical analysis of physical systems, complicated three-dimensional shapes may be broken down to (i.e., approximated by) a mesh representation. The mesh representation may subsequently be used in setting up and solving equations for analysis using a discretization method (e.g. finite volume analysis) which may include numerical solution of partial differential equations based on boundary conditions. Other analysis methods can be used in other examples. Mesh-based analysis techniques are used widely in the fields of computational fluid dynamics (CFD), aerodynamics, electromagnetic fields, civil engineering, chemical engineering, naval architecture and other fields of engineering as well as manufacturing and fabrication processes, such as additive manufacturing processes.
System and method are provided for a real-time simulation of a physical system using an iterative solver, such as a finite volume solver, or other solvers having a convergence stopping criterion. The method includes: calculating a potential solution for a set of equations used to simulate a characteristic for a model modeling a physical system; determining a difference between the potential solution and a previously calculated potential solution; determining if a stop condition is satisfied based on the difference, where the calculation is performed iteratively until the stop condition is satisfied; and generating an output to indicate the potential solution as a steady state solution or a stall solution for the simulated characteristic of the physical system according to the determining if the stop condition is satisfied.
The aspects and embodiments described herein can include non-transitory machine readable media that store executable computer program instructions that when executed can cause one or more data processing systems to perform the methods described herein when the computer program instructions are executed by the one or more data processing systems. The instructions can be stored in nonvolatile memory such as flash memory or dynamic random access memory which is volatile or other forms of memory.
The above summary does not include an exhaustive list of all embodiments in this disclosure. All systems and methods can be practiced from all suitable combinations of the various aspects and embodiments summarized above, and also those disclosed in the Detailed Description below.
The present disclosure is illustrated by way of example and not limitation in the figures of the accompanying drawings, in which like references indicate similar elements and in which:
A typical approach is to use a residual, ri=F(Ui), as an indicator of the error e1 or the closeness of the potential solution to a target solution. In practice, the iterative process is stopped when the residual is relatively small, that is,
where ∈ is a convergence tolerance value, and ro is a residual value based on an initial guess of the solution.
However, a residual approach requires the convergence tolerance, E, to be adjusted based on the value of ro, and the value of ro or a change of ro is dependent on a model of the physical system being simulated, e.g., ri ∝F(Ui) ∝ mesh size, e.g., mesh size dependent. Thus, the stopping criterion (e.g., convergence tolerance) and/or a rate of convergence is dependent on a mesh size of the model. In other words, a finer mesh size for the same model would require a different E for convergence, which if E is chosen incorrectly the simulation system can have an increased computational load and an increased time to convergence. Here, mesh size refers to a size of a mesh element. A model can be made up of a number of mesh elements or cells. For example, a 3D model made up of 100×100×50 elements can have mesh size of (dx, dy, and dz) for the dimensions of a single cell in a xyz coordinate system.
Furthermore, reconfiguration of the inputs for the physical model or other input parameters can require additional manual adjustments for one or more simulation parameters (e.g., convergence tolerance, residual value) for the simulator/solver. Thus, the simulation has to be restarted after reconfiguration.
To configure a simulation, a formulation (or a set of equations or an objective function) is applied to a model of the physical system. The formulation specifies the properties of the model and/or the types of simulations to simulate. These simulations can include simulations for structural, electromagnetics, fluid dynamics, aerodynamics, etc. The solver can iterate over a finite dimensional solution space to determine a potential solution for the formulation.
In one embodiment, a Jacobian (or Hessian) function,
is specified tor the objective function. Because the solver has information about the Jacobian (gradient information) at various points of the simulation, convergence can be achieved at a faster rate. In one embodiment, the iterative process is relaxed. In this case, the Jacobian,
is replaced with {tilde over (J)}=J+ωdiag(J), where ω is a relaxation parameter applying a slope to the Jacobian. If the slope or the relaxation parameter is a large value, the iterations can generate potential solutions that overshoots which cause oscillations or a stall. However, applying a small slope relaxes the iterations, thus, improving a convergence for the simulation.
At block 403, processing logic determines a difference or an amount of change, ΔUi−1=U1−Ui−1, between the calculated solution and a solution of a previous iteration (e.g., a pair of solutions). At block 405, processing logic determines if the potential solutions or the amount of change between the pair of solutions produced by two consecutive iterations satisfies a stop condition. If the change in the solution is relatively small, the solution has either converged to an exact solution or the iterative process has stalled. E.g., the potential, Ui, at the ith iteration has converge to a particular solution independent of a target (or true) solution, Uo.
In one embodiment, the stop condition includes a convergence criterion or a stall criterion. In one embodiment, the stop condition includes a condition that the potential solution converged to a target solution. In one embodiment, a convergence criterion includes the condition that a percentage change in the potential solution or a sum of absolute value of a percentage change in the potential solution is smaller than a predetermined threshold, e.g.,
Here, the type of norm used is 1-norm, e.g., a sum of absolute values. In one embodiment, E is specified to be 0.01. In this case, the convergence condition is independent of F(U), or independent of a mesh size.
In one embodiment, a stall criterion includes the condition that the potential solution oscillates back and forth over a number of iterations. For example, a stall criterion can be detected to have occurred over a hundred iterations or any number of iterations based on some predetermined conditions. In one embodiment, the predetermined conditions include, computing a moving average for a change of the potential solution and/or a moving average for a change of the residual. The moving averaging help smooth the data by filtering out any noise. E.g., removing the one-off fluctuations. Then the moving averages over the last 100 iterations (or a history of past iterations) can be compared for consistencies. If the comparison for the consistency indicates the moving average has not change or gone up in the last number of iterations (e.g., 100 iterations) then it is determined the simulation have stalled. For example:
for k=1, 2, . . . , N (where Nis any number>2, such as 100)
if
where α is a moving average coefficient for the difference of potential solutions, β is a moving average coefficient for the residual, and the type of norm used is 1-norm, e.g., a sum of absolute values. Both a and β can be preconfigured with default values or may be specified by a user. In one embodiment, a or β is specified to be 0.05.
In one embodiment, the stop condition includes a modified convergence criterion to maintain mesh independence for a solver that uses a modified relaxed Jacobian matrix, the modified convergence criterion can be:
where
hi is the size of mesh cell i, ω is the relaxation factor, and the type of norm used is 1-norm, e.g., a sum of absolute values.
If a stop condition is satisfied, at block 407, processing logic stops the iterations and the simulation result outputs the potential solution at the stop condition. If the stop condition is a stall condition, the simulation result can output any of a number of solutions (an averaged value, a value from the last iteration, etc.) surrounding the stall condition. Otherwise processing logic continues to block 401.
In one embodiment, the stopping condition includes a convergence condition or a stall condition. In another embodiment, the convergence condition indicates the potential solution has converted to a particular solution independent of a target solution. In one embodiment, the calculation is performed iteratively using a relaxation method. In one embodiment, the physical system is modeled by generating one or more mesh to represent the physical system and a stopping criterion for the simulation is independent of a size of the generated mesh.
In one embodiment, the simulation of the physical system includes a simulation for structural analysis, fluid analysis, thermal analysis, or aerodynamics analysis and the simulation includes a steady state simulation solving for a steady state for the simulation. In one embodiment, the stop condition is independent of a residual of the solution.
The methods and systems described herein may be implemented using any suitable processing system with any suitable combination of hardware, software and/or firmware, such as described below with reference to the non-limiting examples of
A disk controller 260 interfaces one or more optional disk drives to the system bus 252. These disk drives may be external or internal floppy disk drives such as 262, external or internal CD-ROM, CD-R, CD-RW or DVD drives such as 264, or external or internal hard drives 266. As indicated previously, these various disk drives and disk controllers are optional devices.
Each of the element managers, real-time data buffer, conveyors, file input processor, database index shared access memory loader, reference data buffer and data managers may include a software application stored in one or more of the disk drives connected to the disk controller 260, the ROM 256 and/or the RAM 258. Preferably, the processor 254 may access each component as required.
A display interface 268 may permit information from the bus 256 to be displayed on a display 270 in audio, graphic, or alphanumeric format. Communication with external devices may optionally occur using various communication ports 272.
In addition to the standard computer-type components, the hardware may also include data input devices, such as a keyboard 272, or other input device 274, such as a microphone, remote control, pointer, mouse, touchscreen and/or joystick.
This written description describes exemplary embodiments of the invention, but other variations fall within scope of the disclosure. For example, the systems and methods may include and utilize data signals conveyed via networks (e.g., local area network, wide area network, internet, combinations thereof, etc.), fiber optic medium, carrier waves, wireless networks, etc. for communication with one or more data processing devices. The data signals can carry any or all of the data disclosed herein that is provided to or from a device.
The methods and systems described herein may be implemented on many different types of processing devices by program code comprising program instructions that are executable by the device processing system. The software program instructions may include source code, object code, machine code, or any other stored data that is operable to cause a processing system to perform the methods and operations described herein. Any suitable computer languages may be used such as C, C++, Java, etc., as will be appreciated by those skilled in the art. Other implementations may also be used, however, such as firmware or even appropriately designed hardware configured to carry out the methods and systems described herein.
The systems' and methods' data (e.g., associations, mappings, data input, data output, intermediate data results, final data results, etc.) may be stored and implemented in one or more different types of computer-implemented data stores, such as different types of storage devices and programming constructs (e.g., RAM, ROM, Flash memory, flat files, databases, programming data structures, programming variables, IF-THEN (or similar type) statement constructs, etc.). It is noted that data structures describe formats for use in organizing and storing data in databases, programs, memory, or other non-transitory computer-readable media for use by a computer program.
The computer components, software modules, functions, data stores and data structures described herein may be connected directly or indirectly to each other in order to allow the flow of data needed for their operations. It is also noted that a module or processor includes but is not limited to a unit of code that performs a software operation, and can be implemented for example as a subroutine unit of code, or as a software function unit of code, or as an object (as in an object-oriented paradigm), or as an applet, or in a computer script language, or as another type of computer code. The software components and/or functionality may be located on a single computer or distributed across multiple computers depending upon the situation at hand.
It should be understood that as used in the description herein and throughout the claims that follow, the meaning of “a,” “an,” and “the” includes plural reference unless the context clearly dictates otherwise. Also, as used in the description herein and throughout the claims that follow, the meaning of “in” includes “in” and “on” unless the context clearly dictates otherwise. Finally, as used in the description herein and throughout the claims that follow, the meanings of “and” and “or” include both the conjunctive and disjunctive and may be used interchangeably unless the context expressly dictates otherwise; the phrase “exclusive or” may be used to indicate situation where only the disjunctive meaning may apply.
| Number | Date | Country | |
|---|---|---|---|
| 62933213 | Nov 2019 | US |
| Number | Date | Country | |
|---|---|---|---|
| Parent | 16705921 | Dec 2019 | US |
| Child | 18096009 | US |