An automated transformer 3D modeling method and apparatus
Patent Information
- Application Number
- CN202611120057.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-27
- Publication Date
- 2026-10-23
- Estimated Expiration
- 2046-07-27
AI Technical Summary
[0004]有鉴于此,本申请提供一种自动化变压器3D建模方法和装置,用以解决变压器建模通用性不强、效率低的问题
[0016]本申请提供的自动化变压器3D建模方法和装置,通过将变压器结构特征抽象为多维编码与变量,系统性地划分为固定变量与可扫描优化变量,固定变量作为建模过程中的不变基准,确定结构编码、阵列数量和匝数基准,保障模型拓扑一致性;优化变量作为可扫描参数,直接驱动磁芯尺寸、PCB厚度、气隙长度及绕组间距的动态调节,并支持仿真参数扫描,使分类结果贯穿衍生参数计算、几何生成与约束校验全流程,实现拓扑稳定与设计灵活的统一;在此基础上自动计算磁芯高度、结构间距等衍生参数,消除了手动计算误差;最终基于Python与pyAEDT环境,按照几何装配依赖顺序一键生成完整3D模型。彻底替代了传统手动绘制与反复修改的建模方式,使模型生成完全自动化、参数化,支持快速修改编码或变量即可自动更新模型,显著缩短建模周期;同时,通过优化变量支持仿真参数扫描,便于快速迭代与方案寻优;高兼容的编码框架可适配任意绕组排布、层厚配置及磁芯阵列结构,一套模型覆盖多规格需求,极大提升了PCB变压器设计的灵活性与研发效率。
Smart Images

Figure CN122636880B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of transformer design technology, and in particular to an automated transformer 3D modeling method and apparatus. Background Technology
[0002] With the rapid development of high-frequency and modular power conversion technologies, PCB transformers have been widely used in the field of switching power supplies due to their advantages such as compact structure, low parasitic parameters, and good consistency. In the design and simulation verification of PCB transformers, it is necessary to quickly construct three-dimensional models that adapt to different winding arrangements, PCB layer structures, core sizes, and array forms to meet the needs of electromagnetic simulation, structural verification, and scheme iteration.
[0003] Currently, existing 3D modeling methods for PCB transformers largely rely on manual operations. For example, they involve manually drawing the magnetic core, PCB substrate, and winding structure using general-purpose 3D modeling software. This process is cumbersome in terms of parameter modification, has poor model reusability, and lacks versatility. Traditional modeling methods cannot achieve flexible expansion of the magnetic core column, nor can they quickly set and adjust the winding structure. Furthermore, they cannot support the programmed generation of multi-unit matrix transformer structures. This results in long 3D modeling cycles and low modification efficiency for PCB transformers, making it difficult to quickly adapt to the design and simulation verification needs of PCB transformers with multiple specifications and structures. This severely restricts product development efficiency and the scope for solution optimization. Summary of the Invention
[0004] In view of this, this application provides an automated transformer 3D modeling method and apparatus to solve the problems of poor versatility and low efficiency in transformer modeling.
[0005] Specifically, this application is implemented through the following technical solution:
[0006] The first aspect of this application provides a method for 3D modeling of automated transformers, the method comprising:
[0007] Obtain modeling parameters, which include at least the number of transverse units, the number of longitudinal units, layer distribution coding, serial-parallel coding, layer thickness coding, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure;
[0008] The modeling parameters are divided into fixed variables and optimization variables;
[0009] Calculate the derived parameters based on the modeling parameters;
[0010] The code runs on the Python and pyAEDT environment, reads the modeling parameters and the derived parameters, determines the modeling execution order according to the geometric assembly logic, and generates a complete 3D geometric model of the PCB transformer.
[0011] A second aspect of this application provides an automated transformer 3D modeling device, the device comprising an acquisition module, a processing module, and a generation module;
[0012] The acquisition module is used to acquire modeling parameters, which include at least the number of horizontal units, the number of vertical units, the layer distribution code, the serial-parallel code, the layer thickness code, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure.
[0013] The processing module is used to divide the modeling parameters into fixed variables and optimization variables;
[0014] The processing module is also used to calculate derived parameters based on the modeling parameters;
[0015] The generation module is used to run code based on Python and pyAEDT environment, read the modeling parameters and the derived parameters, determine the modeling execution order according to geometric assembly logic, and generate a complete 3D geometric model of PCB transformer.
[0016] The automated transformer 3D modeling method and apparatus provided in this application abstracts the structural features of the transformer into multi-dimensional codes and variables, systematically dividing them into fixed variables and scannable optimization variables. The fixed variables serve as invariant benchmarks in the modeling process, determining the structural codes, array quantity, and turn count benchmarks to ensure model topology consistency. The optimization variables, as scannable parameters, directly drive the dynamic adjustment of core size, PCB thickness, air gap length, and winding spacing, and support simulation parameter scanning. This allows the classification results to be integrated throughout the entire process of derived parameter calculation, geometry generation, and constraint verification, achieving a balance between topology stability and design flexibility. Based on this, derived parameters such as core height and structural spacing are automatically calculated, eliminating manual calculation errors. Finally, based on the Python and pyAEDT environment, a complete 3D model is generated with one click according to the geometric assembly dependency order. It completely replaces the traditional manual drawing and repeated modification modeling method, making model generation fully automated and parametric. It supports automatic model updates by quickly modifying codes or variables, significantly shortening the modeling cycle. At the same time, it supports simulation parameter scanning by optimizing variables, which facilitates rapid iteration and solution optimization. The highly compatible coding framework can adapt to any winding arrangement, layer thickness configuration and magnetic core array structure. One model covers multiple specification requirements, which greatly improves the flexibility and R&D efficiency of PCB transformer design. Attached Figure Description
[0017] Figure 1 A flowchart of an embodiment of the automated transformer 3D modeling method provided in this application;
[0018] Figure 2 This is a schematic diagram of the structure of Embodiment 2 of the automated transformer 3D modeling device provided in this application. Detailed Implementation
[0019] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application.
[0020] The terminology used in this application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The singular forms “a,” “the,” and “the” used herein are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.
[0021] It should be understood that although the terms first, second, third, etc., may be used in this application to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, without departing from the scope of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to determination."
[0022] The following specific embodiments are given to illustrate the technical solution of this application in detail.
[0023] Figure 1 This is a flowchart of an embodiment of the automated transformer 3D modeling method provided in this application. Please refer to... Figure 1 The method provided in this embodiment may include:
[0024] S101. Obtain modeling parameters, which include at least the number of transverse units, the number of longitudinal units, the layer distribution coding, the serial-parallel coding, the layer thickness coding, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure.
[0025] Specifically, the core array parameters are defined, including the number of horizontal and vertical units. These represent the number of repeating units in the horizontal and vertical directions, respectively, and are used to control the multi-unit matrix or horizontal array transformer structure. Layer distribution codes are defined, in string form, with a length equal to the total number of PCB layers. Each character corresponds to the winding attribute of a PCB layer, where character 1 indicates the current layer is the primary winding layer, and character 0 indicates the current layer is the secondary winding layer. Series-parallel codes are defined, in binary strings, with each character corresponding to the electrical connection method of a group of windings. The first code value indicates a series connection, and the second code value indicates a parallel connection. Layer thickness codes are defined, in numerical strings, with each value corresponding to the thickness of a PCB layer, supporting independent assignment of thickness for each layer. The number of turns per primary layer and per secondary layer variables are defined, specifying the number of turns in each primary and secondary layer winding, respectively.
[0026] Furthermore, users provide the number of horizontal and vertical units through configuration files, command-line parameters, or script variables. These parameters collectively determine the layout of the core array. A horizontal array is formed when the number of vertical units is equal to one; a matrix array is formed when both the number of horizontal and vertical units are greater than one. A string is also provided as a layer distribution code. The system records this string and verifies its length against the set number of PCB layers. The user provides a series-parallel encoding, which is stored bit-by-bit, with each bit corresponding to an independent winding group. A layer thickness code is also provided, parsing the thickness value of each layer bit-by-bit and storing it in a layer thickness list. Variables for the number of turns per layer on the primary and secondary sides are also provided. These variables can be single values or arrays; all layers can use the same number of turns, or each layer can have a unique number of turns. After reading all parameters, they are stored as an internal data structure for use in subsequent steps.
[0027] Furthermore, the layer distribution encoding uses string encoding, where the character 1 represents the primary winding and the character 0 represents the secondary winding. The winding layer order and number of layers in the transformer are determined based on this string encoding. The series-parallel encoding controls the winding connection state through encoding bits.
[0028] Specifically, the multi-layer structure of PCB transformers naturally has a sequential arrangement characteristic. The layer distribution coding uses string coding and uses "1" and "0" to identify the primary winding layer and the secondary winding layer, respectively. Each bit of the string naturally corresponds to each physical layer. This intuitive character mapping method allows users to adjust the layer order and quantity ratio of the primary and secondary windings arbitrarily by simply modifying the string sequence without understanding the underlying geometric drawing logic. In multi-winding or multi-unit transformers, different winding groups may use different electrical connection methods to meet the voltage and current matching requirements. The series-parallel coding controls the connection state of each winding group through independent coding bits, and maps each coding bit to the series-parallel connection state of a winding group, realizing fine control of complex connection topologies. For example, in practical use, users can directly provide two coded strings during the design input phase. The layer distribution code, such as "101010", determines which layers are primary and which are secondary. The series-parallel code, such as "10", indicates that the first set of windings is connected in series and the second set of windings is connected in parallel. After the modeling code automatically parses these two strings, it generates the winding conductors of the corresponding layers according to their positions and assigns the correct primary and secondary attributes. On the other hand, it automatically adds series or parallel electrical connections between the winding ports according to the coded positions. This simplifies the complex operation of manually configuring layer attributes and connection relationships to two string inputs, supports zero-cost switching of winding layout schemes and electrical topologies, greatly improves the flexibility of transformer design and model reconstruction efficiency, and avoids human errors when manually wiring or connecting.
[0029] Furthermore, the number of turns in each layer of the primary winding is determined based on the variable number of turns per layer of the primary winding, and the number of turns in each layer of the secondary winding is determined based on the variable number of turns per layer of the secondary winding.
[0030] Specifically, the number of turns per layer on the primary side and the number of turns per layer on the secondary side can accept either a single value or an array of the same length as the number of layers. That is, all primary or secondary layers can use the same number of turns, or each layer can have its own independently specified number of turns. Based on the layer distribution code, it is determined which layers belong to the primary side and which belong to the secondary side. The values of the number of turns per layer on the primary side and the number of turns per layer on the secondary side are read respectively. If it is a single value, the same number of turns is assigned to all primary layers, and a different number of turns is assigned to all secondary layers. If it is an array, the array elements are assigned to the corresponding primary or secondary layers one by one in the layer order. The pyAEDT geometry drawing function is called to automatically generate the geometry of the planar helical winding or wire winding conductor based on the assigned number of turns for each layer. In this way, the number of turns in any layer can be modified in milliseconds without redrawing the conductor structure, thus flexibly adapting to different transformation ratios and excitation inductance requirements; at the same time, it supports differentiated turn number design for each layer, such as 2 turns in the first layer and 3 turns in the second layer on the primary side, providing a fine-grained means of parameter adjustment to suppress the skin effect, optimize winding losses, or adjust leakage inductance, significantly improving the freedom and iterative efficiency of transformer electromagnetic design.
[0031] S102. Divide the modeling parameters into fixed variables and optimization variables.
[0032] Specifically, parameters in the modeling parameters that belong to the transformer topology definition and do not need to participate in the simulation parameter scan are identified and marked as fixed variables; parameters in the modeling parameters that belong to the geometric dimension adjustment category and need to participate in the simulation parameter scan for optimization iteration are identified and marked as optimization variables; fixed variables and optimization variables are stored in different parameter sets, and simulation scan attribute identifiers are added to the optimization variables so that the values of these variables can be automatically traversed in the simulation environment.
[0033] Furthermore, all modeling parameters are iterated to determine whether they belong to the transformer's basic structure code and static topology definition. The number of horizontal units, the number of vertical units, the layer distribution code, the series-parallel connection code, and the layer thickness code are categorized into the fixed variable set, as these parameters determine the transformer's layer topology, array form, and electrical connection architecture, and typically remain unchanged during the optimization process. The number of turns per layer on the primary side and the number of turns per layer on the secondary side are categorized into the optimization variable set. Parameters not explicitly listed in the initial parameter list but belonging to the geometric adjustment category, such as core size parameters, PCB total thickness adjustment coefficient, air gap length, and winding spacing, are also added to the optimization variable set. Fixed variables are used to determine the structural code, the number of core array elements, and the winding turn reference, while optimization variables are used to adjust the core size, PCB thickness, air gap length, and winding spacing. Scan attributes are attached to the optimization variables, including variable name, value range, and a list of step values or discrete values. This information can be provided by the user or read from the default configuration. After partitioning, two parameter tables are generated, one for use by the immutable module and the other by the variable module in the subsequent modeling process.
[0034] Furthermore, the step of dividing the modeling parameters into fixed variables and optimization variables includes:
[0035] (1) Determine the basic structural parameters of the transformer;
[0036] Specifically, the layer distribution code specifies the arrangement order of the primary and secondary winding layers and the number of layers of each type, which is the fundamental definition of the transformer's electrical function. The series-parallel code specifies whether the electrical connection between each winding group is series or parallel, directly determining the voltage and current transformation relationship. The number of horizontal and vertical units defines the layout of the core array, determining the transformer's physical expansion structure and power rating adaptability. Once these four parameters are set, the transformer's winding layer attributes, electrical connection topology, and array shape are uniquely locked. Any subsequent adjustments to the geometric dimensions will not change this topological framework. Therefore, the layer distribution code, series-parallel code, number of horizontal units, and number of vertical units are the most basic and highest-priority structural parameters to be determined.
[0037] (2) Based on the basic structural parameters, select the fixed variables and optimization variables in the modeling parameters.
[0038] Specifically, the layer distribution code, serial-parallel code, number of horizontal units, and number of vertical units in the basic structural parameters are directly categorized into the fixed variable set. Since each bit of the layer thickness code corresponds to each physical layer defined by the layer distribution code in the basic structural parameters, and layer thickness is a fixed manufacturing parameter of the PCB, it is usually not used as a scanning variable in design optimization. Therefore, the layer thickness code is also treated as a fixed variable. Since the number of turns in the primary and secondary windings can be adjusted independently without changing the layer distribution code, they are scannable optimization parameters. Therefore, the number of turns per primary winding and the number of turns per secondary winding are treated as optimization variables. Geometric parameters such as core size parameters, PCB total thickness adjustment coefficient, air gap length, and winding spacing are categorized into the optimization variable set. These parameters are not included in the basic structural parameters and can be scanned to find their optimal values. Each parameter in the optimization variable set is assigned a scanning attribute, including variable name, data type, value range, and default step value, so that parameter scanning can be performed automatically in the simulation environment.
[0039] Furthermore, the four parameters in the basic structure parameter record table are directly copied to the fixed variable table, since these parameters are defined as immutable basic topology information. The layer thickness code is located, its numerical string is read, and based on the layer distribution code length in the basic structure parameters, it is confirmed that each value of the code corresponds to a physical layer. The entire layer thickness code string is then stored as a parameter in the fixed variable table. Layer thickness is usually determined by the available thickness specifications or insulation withstand voltage requirements of the PCB manufacturing process. In conventional design optimization, it is not used as a scanning variable, otherwise it would lead to frequent reconstruction of the model's layer stack structure, increasing computational complexity.
[0040] Furthermore, the number of turns per layer on the primary side and the number of turns per layer on the secondary side are read and stored in the optimization variable table. The number of primary and secondary layers is automatically calculated based on the layer distribution code in the basic structural parameters. The modeling parameter list is scanned to check for core size parameters; if not, preset initial values are read from the default configuration file and added to the optimization variable table. Similarly, air gap length, winding spacing, and PCB total thickness adjustment coefficient are checked; if missing, default values are added. All these parameters are categorized into the optimization variable table because they directly determine the transformer's electromagnetic performance and mechanical dimensions and can vary independently without altering the basic topology. The fixed variable table and the optimization variable table are stored separately for subsequent calculation of derived parameters and geometric modeling. Using the basic structural parameters as an objective benchmark, parameter classification is automated and standardized, ensuring that fixed variables protect the transformer's topological stability, while optimization variables cover all adjustable geometric dimensions. This provides a clear variable management system for efficient parameter scanning and scheme iteration.
[0041] Furthermore, the structural code, the number of magnetic core arrays, and the number of winding turns are determined based on the fixed variables, and the magnetic core size, PCB thickness, air gap length, and winding spacing are adjusted based on the optimized variables.
[0042] Specifically, the layer distribution code is directly read from the fixed variable set as the winding structure code, and the coded string is output to the PCB layer attribute definition module to determine whether each layer is a primary or secondary side. At the same time, the number of horizontal and vertical units is read and the product is calculated as the total number of core arrays, which is used to generate multi-unit matrices or horizontal arrays through double loops during geometric modeling. Then, the default initial values or array length information of the number of turns per layer of the primary side and the number of turns per layer of the secondary side are read as the winding turn reference for reference during subsequent conductor generation. The core size, PCB thickness, air gap length, and winding spacing parameters are read one by one from the optimization variable set, and these geometric variables are directly passed to the pyAEDT geometry drawing interface to dynamically adjust the size of the core entity, the thickness of each PCB dielectric layer, the cutting depth of the air gap in the core column, and the insulation distance between adjacent winding layers. Since the fixed variables, such as the layer distribution code, array quantity, and turns reference, essentially define the transformer's topological skeleton, these core features, once determined, cannot be arbitrarily changed during optimization scanning; otherwise, the comparability between different schemes would be lost. In contrast, the optimization variables only involve pure geometric adjustments, seeking optimal electromagnetic performance through parameter scanning without altering the topology. By completely decoupling topology definition from geometric tuning, batch parameter scanning and iterative optimization of core size, PCB thickness, air gap length, and winding spacing can be efficiently performed while maintaining the winding layer order, core array form, and turns reference unchanged. This avoids model failure caused by erroneous changes to structural coding and significantly improves the efficiency of design space exploration.
[0043] Furthermore, when reading different parameter groups, optimization weights are assigned to each group, with the optimization variable group having the highest weight. Within each group, parameters are sorted according to their sensitivity to electromagnetic performance, with weights decreasing sequentially to represent optimization priority. The first-level iterative optimization is performed, allowing the optimization variables to traverse values within a preset scanning range until a preset first stopping condition is reached, obtaining the optimal combination of optimization variables. Upon reaching the first stopping condition, the simulator performance difference before and after adjusting the fixed variables is calculated based on the optimal combination. If the difference indicates performance improvement, the fixed variables are unlocked, and the second-level iteration begins, adjusting the fixed variables and continuing simulation optimization. If the difference indicates no performance improvement or even a decrease, the current optimal combination is output as the final result, and the iteration stops. By guiding the simulator to prioritize scanning the optimization variables through hierarchical weighting, and then evaluating the benefits of adjusting the fixed variables after the optimization variables converge, efficient allocation of computational resources is achieved, avoiding indiscriminate exhaustive scanning of all variables. Simultaneously, the search range of the design space is further expanded without significantly increasing the number of simulations.
[0044] Furthermore, regarding the quantification of optimization weights, sensitivity is obtained by pre-scanning each optimization variable using a univariate method. This involves keeping other parameters constant and only changing the target variable, recording the changes in electromagnetic performance such as inductance, loss, or efficiency. The normalized rate of performance change is then used as the sensitivity coefficient for that variable. Weights are assigned directly based on this coefficient, sorted from largest to smallest; higher sensitivity results in higher weights, guiding optimization to prioritize adjusting the most significantly affected variables. The first stopping condition is defined as follows: when the relative improvement of the objective function is below a preset threshold for N consecutive iterations, the optimization variable is considered to have converged to a local optimum, thus meeting the first stopping condition. When adjusting fixed variables in the second-level iteration, the topological definitions such as layer distribution coding and serial-parallel coding are not changed, but rather the fixed variables are adjusted. The physical size boundaries of the constraints, such as appropriately relaxing the upper limit of the core window height or the number of winding layers while keeping the order and array number of the primary and secondary windings unchanged, are adjusted. This means adjusting the size constraint boundaries implicit in the structural coding, allowing the core size to participate in optimization within a wider range, in order to explore whether performance can be further improved without changing the topology skeleton. If the performance is improved, the adjusted boundary is retained; otherwise, it reverts to the original value. The essence of this hierarchical iteration is to first lock the topology to stability and then gradually loosen the size constraints. This strategy ensures the comparability of the schemes and expands the search range of the design space. The output model always uses the topology skeleton determined by fixed variables as the benchmark, and only makes adaptive fine adjustments to its size boundaries, without destroying the basic structural definition and electrical connection topology of the transformer.
[0045] S103. Calculate the derived parameters based on the modeling parameters.
[0046] Specifically, the process involves obtaining the layer thickness code from the fixed variables and calculating the sum of the thicknesses of each layer to obtain the total PCB thickness; obtaining the core size parameter and air gap length parameter from the optimized variables and calculating the core height based on the total PCB thickness; obtaining the winding spacing parameter from the optimized variables and calculating the geometric spacing values corresponding to the electrical clearance and creepage distance between adjacent winding layers; and storing the calculated core height and structural spacing as derived parameters in a derived parameter table for direct reference during geometric modeling. Derived parameters refer to geometric dimension parameters that cannot be directly obtained from the input but require calculation or logical derivation based on the input modeling parameters.
[0047] Furthermore, the geometric spacing value refers to the minimum safe distance that needs to be maintained between adjacent winding layers. This can include electrical clearance and creepage distance. Electrical clearance is the shortest straight-line distance between two conductive components in air, used to prevent air breakdown under transient overvoltage. Creepage distance is the shortest path distance along the surface of a solid insulating material, used to prevent surface leakage under long-term operating voltage. Both must be satisfied simultaneously, and the creepage distance is usually greater than the electrical clearance. The calculation of the spacing value is based on factors such as operating voltage, pollution level, material group, and altitude. Electrical clearance is calculated based on transient peak voltage, and creepage distance is determined by multiplying the effective value of the operating voltage by the creepage ratio. Higher pollution levels and poorer material insulation performance require larger spacing. In this embodiment, the code determines which layers have voltage differences based on the layer distribution encoding. Combined with the user-input operating voltage parameters, it automatically calculates the corresponding electrical clearance and creepage distance according to preset safety standards. The larger of the two values is taken as the geometric spacing value for the adjacent winding layer pair and passed to the pyAEDT geometry drawing interface. When the winding conductor is generated, an insulation spacing structure of appropriate thickness is automatically inserted between the layers, thereby ensuring that the model complies with electrical safety specifications.
[0048] Furthermore, the layer thickness code is parsed, and each thickness value is summed to obtain the total thickness of the PCB substrate. The core size parameters from the optimization variables are read, including the width of the core pillar, the width of the side pillars, and the height of the core window. Simultaneously, the air gap length parameter is read, and the height calculation formula is determined based on the core's mechanical structure. Typically, the total core height equals the core cover thickness plus the side pillar height plus the base thickness, minus half or all of the air gap length, depending on the air gap location, to obtain the core height value. The winding spacing parameter is further read. This parameter can be a global value or multiple independent values for primary and secondary sides, and between layers. Based on the PCB layer distribution code, it is determined which layers have voltage differences, and then the required geometric spacing values are calculated. All calculated values are encapsulated into a derived parameter table, including core height, structural spacing, and total PCB thickness. These derived parameters eliminate the need for manual calculation of related dimensions, achieving adaptive size matching.
[0049] Furthermore, the mechanical structure of the magnetic core is determined by the preset core model variable in the code. This core model variable is one of the modeling parameters input by the user, and its values correspond to different core series, including EE, ER, PQ, EP, and can-shaped cores. Each model has different geometric topological characteristics. For example, an EE core consists of two E-shaped halves joined together, with the center post and side posts having the same height. An ER core has a circular cross-section for its center post, while a PQ core uses a rounded transition design for both the center post and side posts. The height calculation methods differ for each type. Based on the read core model variable, the code automatically matches the corresponding mechanical structure parameter template and extracts the model definition data, including the center post cross-sectional shape, the number and distribution of side posts, the cover plate thickness, the base thickness, and key dimensions such as the window height. Based on this, the code adds the window height to the thickness of the upper and lower cover plates according to the structural formula corresponding to the core model to obtain the theoretical total height of the side post, which is the core height reference value. For example, the height of the middle post of the EE type core is the same as the height of the side post, and this value is directly used as the minuend. However, for the PQ type core, the equivalent height needs to be calculated separately according to the arc cross-section as the minuend. The code determines the value of the minuend according to the air gap opening position indicator. The indicator is a parameter input by the user or provided by the default configuration of the core model. When the indicator indicates that the air gap is opened in the middle of the middle post, the minuend is half the length of the air gap. When the middle post needs to be evenly divided into upper and lower sections, half the length of the air gap is subtracted from the minuend to obtain the actual height of each section of the middle post. When the indicator indicates that the air gap is opened at one end of the middle post (near the upper or lower cover plate), the minuend is the entire length of the air gap. The remaining height of the middle post is obtained by directly subtracting the complete length of the air gap from the minuend. By automatically matching the structural formula with the core model variable to determine the minuend and determining the minuend value by the air gap opening position identifier, the adaptive calculation of the core height under different mechanical structure forms can be achieved.
[0050] Furthermore, the steps for calculating derived parameters based on the modeling parameters include:
[0051] (1) Obtain the core size, total PCB thickness, and air gap length from the modeling parameters;
[0052] Specifically, the core size parameters are read from the optimization variables section of the modeling parameter set. These parameters include the width of the core center column, the width of the core side column, and the height of the core window. The layer thickness code is read from the fixed variables section of the modeling parameter set. The thickness values of each bit of the code are summed to calculate the total PCB thickness. The air gap length parameter is read from the optimization variables section of the modeling parameter set. The air gap length parameter represents the thickness value of the air gap that needs to be opened on the core center column of the transformer.
[0053] (2) Calculate the initial value of the magnetic core height based on the magnetic core size, the total thickness of the PCB, and the air gap length;
[0054] Specifically, the basic height range of the magnetic core side pillars is determined based on the window height and side pillar width in the magnetic core dimensions; the total PCB thickness is taken as the total substrate thickness that needs to be accommodated within the magnetic core window, and the theoretical height of the magnetic core center pillar and side pillars is calculated in combination with the reserved thickness of the upper and lower cover plates of the magnetic core; the air gap length parameter is introduced, and half or all of the air gap length is subtracted from the theoretical height to obtain the initial value of the magnetic core height.
[0055] Furthermore, the core model used in the current transformer is identified, as different core models correspond to different height calculation formulas. Taking the EE type core as an example, the total height of the core consists of the side post height and the thickness of the upper and lower cover plates. The side post height must be greater than or equal to the total PCB thickness plus the winding conductor thickness and the necessary insulation gap. The window height is read from the core size parameters. The window height is actually the vertical space inside the core side post that can be used to place the PCB substrate and windings. The total PCB thickness is used as the substrate height, and the total thickness of the winding conductor is estimated based on the thickness of each copper foil layer and the number of turns. The substrate height is added to the total winding conductor thickness to obtain the minimum required window height. The system reads the side post width from the core size and, combined with the core's mechanical structure parameters (such as cover plate thickness), calculates the complete height of the core side post. Generally, the core side post height is equal to the sum of the window height and the thickness of the upper and lower cover plates. The calculated side post height is used as the baseline value for the core height, and the air gap length parameter is introduced. The air gap is usually opened on the core's central post, and its presence changes the effective magnetic circuit length of the core. In geometric modeling, the air gap is represented as a thin sheet cut from the central core. To maintain the overall dimensions of the core, the remaining height of the central core after the air gap is created should be the original central core height minus the air gap length. The specific value to be subtracted is determined based on the location of the air gap. If the air gap is in the middle of the central core, the central core is divided into upper and lower segments, and the height of each segment is reduced by half the air gap length. If the air gap is at one end, the height of the central core is directly subtracted from the entire air gap length. After performing the subtraction operation, the actual height of the central core is obtained, while the height of the side pillars remains unchanged. The actual height of the central core and the height of the side pillars are combined as the initial value of the core height and stored in the initial value variable.
[0056] (3) Match and correct the initial value of the magnetic core height with the preset step size to obtain the magnetic core height as a derived parameter.
[0057] Specifically, the system reads the preset height step value from the configuration file. This step value represents the minimum increment unit allowed for the core height in geometric modeling. The initial core height value is divided by the preset step value to obtain the quotient and remainder. The system determines whether to round up or down based on the size of the remainder, so that the corrected height value is an integer multiple of the step value. The corrected height value is used as the final core height derived parameter and output to the geometric modeling module.
[0058] Further, after calculating the initial value of the core height, the matching and correction stage begins to ensure that the final core height parameters meet the dimensional accuracy requirements of the geometric modeling software and satisfy the consistency of variable stepping during parameter scanning. The preset height step size is read; this step size can be customized by the user in the configuration file, with a default value of 0.01 mm. The step size is the smallest unit of change in core height during parameter scanning. If the core height is not an integer multiple of the step size, rounding errors will occur during scanning, leading to incorrect model updates or discontinuous simulation results. The initial core height is divided by the preset step size; if the remainder is zero, no correction is needed, and the initial value is directly output as the final derived parameter. If the remainder of the initial value and the preset compensation is not zero, the remainder is compared to half the step size. If the remainder is less than or equal to half the step size, it is rounded down; if the remainder is greater than half the step size, it is rounded up. After the rounding operation, the corrected core height value is obtained. When drawing the core entity, the geometric modeling module directly reads the derived parameters as the actual height dimension of the core. This ensures that the core height is always an integer multiple of the preset step size, eliminating modeling errors and parameter scanning failures caused by floating-point precision issues, while improving the repeatability and geometric consistency of the model under different parameter values.
[0059] Further, obtain all parameters of the 3D model object to be constructed, including all geometric dimensions, material properties, and topological definition parameters of the 3D model object; based on the structural degrees of freedom information of the 3D model object, select constraint parameters from the all parameters. Constraint parameters are the smallest set of parameters that can uniquely constrain the geometric shape of the 3D model object. The structural degrees of freedom information includes the deformable direction, scalable dimension, and fixed constraint boundary of the 3D model object; generate a numerical dependency graph based on the numerical computational dependencies between the constraint parameters; the numerical dependency graph uses each constraint parameter as a node, and the multiplication, division, addition, subtraction, trigonometric function, or conditional branch operation relationships between parameters as directed edges; identify all nodes in the numerical dependency graph with an in-degree of zero, mark the parameters corresponding to the nodes with an in-degree of zero as independent variables, and use them as variables that can be input by the user; mark the parameters corresponding to the remaining nodes as derived variables; receive the parameter values input by the user, if the user inputs parameters... If the parameter is an independent variable, its input value is directly adopted as the parameter's value. If the parameter input by the user is a derived variable, the input value is marked as a reference value, and the theoretical value of the derived variable is automatically calculated based on the assigned independent variable according to the calculation order from independent variable to derived variable in the numerical dependency graph. The theoretical value is compared with the user-input reference value. If the absolute value of the difference between the two is within a preset tolerance range, the theoretical value is used as the final value of the derived variable. If the absolute value of the difference exceeds the tolerance range, the values of the independent variables related to the derived variable in the numerical dependency graph are adjusted according to a preset fine-tuning strategy, and the theoretical value of the derived variable is recalculated until the absolute value of the difference between the recalculated theoretical value and the reference value falls within the tolerance range, or until the preset maximum number of fine-tuning times is reached, and the theoretical value closest to the reference value is used as the final value. The three-dimensional model is constructed using the final values of all parameters.
[0060] Furthermore, when adjusting the values of independent variables related to the derived variable in the numerical dependency graph according to the preset fine-tuning strategy, if the deviation between the theoretical value of the derived variable and the reference value input by the user exceeds the preset tolerance range, the dependency graph is traversed backward along the directed edges to locate all independent variables that have direct or indirect multiplication, division, addition, or subtraction operations related to the derived variable. The adjustment share is allocated according to the proportion of the partial derivatives of each independent variable with respect to the derived variable. The adjustment step size is the product of the current deviation value and the preset learning rate, and the adjustment direction is the negative gradient direction of the deviation. If the theoretical value is greater than the reference value, the relevant independent variable is decreased proportionally; otherwise, it is increased. Boundary limits are set for each independent variable to prevent over-adjustment. For scenarios where gradient discontinuities arise due to core model branching conditions (e.g., different core structures correspond to different height formulas), the strategy automatically switches to a trial-and-error method, applying fixed fine-tuning increments according to a preset independent variable priority list and recalculating theoretical values one by one until the deviation converges or reaches its upper limit. After each adjustment, all affected derived variables are recalculated forward along the dependency graph, repeating this closed-loop iteration until the theoretical value falls within the tolerance range or reaches the maximum number of fine-tunings. This ensures that, while strictly maintaining the inherent computational consistency between parameters, the system's automatically calculated values effectively approximate the user's empirical reference values. It should be noted that the preset tolerance range, preset learning rate, preset independent variable priority list, and maximum number of fine-tunings are all pre-set according to actual needs; in this embodiment, they are not limited.
[0061] Specifically, the system acquires all parameters of the 3D model object to be constructed. Based on the object's structural degrees of freedom, it selects the smallest set of parameters that can uniquely constrain the object's geometry—the constraint parameters—from the full set of parameters to eliminate redundant parameters and reduce modeling complexity. A directed dependency graph is generated based on the numerical dependencies between the constraint parameters. Nodes with an in-degree of zero are identified as independent variables, and the remaining nodes are identified as derived variables. When a user inputs a parameter value, if it is an independent variable, it is directly adopted; if it is a derived variable, it is marked as a reference value. The system first automatically calculates the theoretical value of the derived variable based on the dependency graph, then compares the deviation between the theoretical value and the reference value. If the deviation is within the tolerance range, the theoretical value is used; if the deviation exceeds the tolerance, a preset fine-tuning strategy is used to adjust the independent variable and recalculate until the theoretical value approaches the reference value within the tolerance range or the maximum number of iterations is reached. This ensures that the derived variables are uniquely determined by the independent variables, maintaining the inherent consistency between parameters, while also allowing users to input reference values based on experience to guide the system towards a specific design goal, effectively integrating automatic system calculations with user experience input.
[0062] S104. Run the code based on Python and pyAEDT environment, read the modeling parameters and the derived parameters, determine the modeling execution order according to the geometric assembly logic, and generate a complete 3D geometric model of the PCB transformer.
[0063] Specifically, the pyAEDT library is imported into the Python environment, and a connection session with Ansys Electronics Desktop is established. The original modeling parameters, fixed variables, optimized variables, and derived parameters are read and passed to the modeling script. The modeling execution order is determined according to the geometric assembly logic: first, the magnetic core is drawn to define the global spatial reference; then, the PCB substrate is positioned and drawn according to the magnetic core window size; next, the winding conductors are drawn on the PCB substrate; finally, the air gap structure is generated on the magnetic core, and the spacing structure is generated between the windings. The geometric drawing functions in pyAEDT are called to create the magnetic core entity, PCB substrate entity, winding conductor entity, air gap cutting feature, and spacing offset feature in the above order. After all geometric elements are created, the relevant components are merged to form a complete PCB transformer assembly, which is then exported as a 3D geometric model file that can be directly recognized by electromagnetic simulation software, or the model is saved in the pyAEDT session for subsequent simulation settings.
[0064] Furthermore, the script checks whether the pyAEDT library is installed in the local Python environment and whether Ansys Electronics Desktop can be started normally. After establishing a connection, the script extracts all parameter values from the parameter storage structure. As the main skeleton of the transformer, the position and size of the magnetic core determine the origin of the coordinate system of the entire model. Therefore, the script first calls the geometric modeling interface of pyAEDT to create a three-dimensional solid representation of the magnetic core based on the magnetic core size parameters and the magnetic core height in the derived parameters. This solid representation includes components such as the central column, side columns, upper cover plate, and lower cover plate. After the magnetic core is drawn, the placement area of the PCB substrate is calculated based on the geometric range of the magnetic core window. The substrate is a multi-layer board structure, and the substrate entity is created layer by layer according to the layer thickness code. The thickness of each layer is set independently. All layers are stacked to form a complete PCB substrate and placed in the correct position within the magnetic core window. Then, the layer distribution code determines whether each layer is a primary winding layer or a secondary winding layer. The number of turns on each layer is determined based on the number of turns per primary and secondary layers. The conductor drawing function of pyAEDT is called to automatically generate planar helical windings or trace-type winding conductors on the corresponding PCB layers. The shape, width, and spacing of the winding conductors are automatically calculated from preset conductor rules and the number of turns. After the winding is drawn, the air gap length parameter is read, and an air gap gap is generated at the specified position of the magnetic core column through Boolean subtraction. The winding spacing parameter is read, and an insulation spacing structure is generated between adjacent winding layers or between the winding and the magnetic core. This is usually represented by an offset entity or a gap area. After all geometric elements are generated, the magnetic core, PCB substrate, winding conductors and spacing structure are combined into a complete assembly model. The model can be saved as a local file or opened directly in the simulation environment to generate a complete 3D geometric model of the PCB transformer with one click.
[0065] Furthermore, the implementation steps for determining the modeling execution order according to the geometric assembly logic include:
[0066] (1) Draw the magnetic core to determine the global spatial reference;
[0067] (2) Determine the PCB substrate based on the magnetic core window;
[0068] (3) Draw the winding conductor on the PCB substrate, and generate the air gap structure and the spacing structure on the magnetic core and the winding conductor respectively.
[0069] Specifically, a complete three-dimensional magnetic core entity is created based on the core size parameters and the core height derived from the core parameters. This entity includes the central column, side columns, upper cover plate, and lower cover plate. The geometric center or bottom vertex of this magnetic core is used as the origin of the global coordinate system to establish the spatial reference of the entire model. The allowable placement area of the PCB substrate is automatically calculated based on the inner boundary dimensions of the core window (including window width and window height). A multi-layer PCB substrate entity matching the window size is generated within this area, with the thickness of each layer independently controlled by the layer thickness code. The layer distribution code determines whether each layer is a primary or secondary edge, and the planar helical winding or trace-type winding conductor is automatically drawn on the corresponding PCB layer based on the number of turns of each layer. The air gap length parameter is read, and a thin sheet is cut off at a specified position of the magnetic core central column using Boolean subtraction to generate an air gap. At the same time, the winding spacing parameter is read, and an insulation spacing structure (usually manifested as an offset entity or gap region) is generated between adjacent winding layers or between the winding and the magnetic core.
[0070] Furthermore, since the magnetic core is the structural skeleton of the transformer, it must exist first to define spatial coordinates and dimensional boundaries; the PCB substrate needs to be precisely placed within the magnetic core window, therefore its position and shape depend on the window size of the magnetic core; the winding conductors must be drawn on the existing PCB substrate, otherwise there is a lack of a carrier and layer positioning basis; the air gap and spacing are post-processing modifications to the generated magnetic core and windings, and reversing the order would lead to missing Boolean operation targets or chaotic geometric relationships. This ensures that the modeling process strictly follows the physical dependencies of geometric assembly, guaranteeing that each drawing operation has a referable parent entity, avoiding redundant coordinate calculations and Boolean operation failures. It also enables one-click automatic updates driven by parameters; after the user modifies any dimensional parameters, the model is automatically reconstructed and always maintains the correct assembly relationships, significantly improving the robustness and efficiency of modeling.
[0071] Furthermore, after calculating the derived parameters based on the modeling parameters, the method provided in this embodiment also includes:
[0072] (1) Compare the derived parameters with the preset geometric constraints;
[0073] Specifically, after calculating the derived parameters, the core height value is located in the derived parameter table and read as a floating-point number. Geometric constraints are then retrieved from the system configuration file or user-specified constraint file. These constraints typically include a set of upper and lower limits. For example, the minimum core height is determined by the minimum machining dimensions of the core material, while the maximum is determined by the transformer installation space limitations. The safety threshold for structural spacing is determined by insulation withstand voltage requirements or manufacturing capabilities; for instance, the creepage distance between the primary and secondary sides must be greater than 0.2 mm. The retrieved core height value is compared with the minimum and maximum height values, generating a Boolean comparison result, recording whether it is below the minimum or above the maximum. Simultaneously, the structural spacing value is compared with the spacing safety threshold to determine if it is greater than or equal to that threshold. These comparison results are stored in a verification result record table for use in the next step.
[0074] (2) If the derived parameter exceeds the range of the constraint, adjust at least one parameter in the optimization variables and recalculate the derived parameter until the derived parameter satisfies the constraint.
[0075] Specifically, if the core height is lower than the minimum or higher than the maximum, the adjustment process is triggered. When the core height is lower than the minimum, the core size parameter in the optimization variables is increased, or the PCB total thickness adjustment coefficient is decreased. When the core height is higher than the maximum, the core size parameter is decreased or the air gap length is increased. If the structural spacing is less than the safety threshold, the winding spacing parameter in the optimization variables is increased. After each adjustment of the optimization variables, the derived parameter calculation step is re-executed, and the core height and structural spacing are recalculated using the updated parameters. The process of comparison, adjustment, and recalculation is repeated until the derived parameters fully meet the constraints or the preset maximum number of iterations is reached, at which point the process exits.
[0076] Furthermore, if any derived parameter exceeds the constraint range, an iterative adjustment loop is initiated. If the core height is below the minimum value, it is determined that the current core size may be too small. Therefore, the core size parameter in the optimization variables is increased by a fixed step size, while keeping the air gap length unchanged. Then, the derived parameter calculation module is called to recalculate the core height. If the core height is above the maximum value, it is determined that the core size may be too large. Therefore, the core size parameter is decreased by a fixed step size, or the air gap length is increased, as increasing the air gap will reduce the effective core height. If the structural spacing is less than the safety threshold, the winding spacing parameter in the optimization variables is directly increased by a fixed step size. After each parameter adjustment, the previously defined derived parameter calculation process is re-executed to re-obtain the core size, total PCB thickness, and air gap length. The initial core height value is recalculated, and step size matching correction is performed again to obtain new derived parameters. The constraint verification module is called again to compare the new derived parameters with the constraint conditions. If the conditions are still not met, the parameters are adjusted and recalculated. If the constraints are still not met after reaching the maximum number of iterations, the system stops the loop, records the current derived parameters, and pops up a warning window prompting the user to manually adjust the initial parameters. Once the derived parameters come within the constraint range, the loop exits, and the final optimized variable values and derived parameter values are recorded. It should be noted that the fixed step size is set according to actual needs; in this embodiment, it is not limited.
[0077] Furthermore, when the derived parameters still exceed the constraint range after reaching the maximum number of iterations, the loop stops to avoid infinite loops and protect the modeling process. The pop-up warning window is not just a simple error message, but will clearly list: the name of the derived parameter that exceeds the limit and its current measured value, the upper and lower limit thresholds of the corresponding constraint, and the combination of optimization variable values currently participating in the iteration, such as the specific values of magnetic core size parameters, air gap length, and winding spacing, and provide directional adjustment suggestions to guide the user to manually modify the initial parameters and then rerun the script. At this stage, derived parameters that do not currently meet the constraints are not passed to the geometric modeling module to generate a formal 3D model that can be used for simulation. Instead, the current geometric state is retained as a preview to be corrected, allowing users to visualize the degree of exceeding the limits. However, this explicitly blocks subsequent electromagnetic simulation or structural verification processes to avoid invalid simulation results due to unreasonable geometric dimensions. In this process, convergence is strictly defined as a Boolean criterion that all derived parameters fall within the preset geometric constraint range. That is, convergence is a hard prerequisite for the model to enter the final generation and simulation stage. When convergence fails, although the model can be partially visualized, it will not obtain a simulation validity indicator. The initial boundary values of the optimization variables must be adjusted according to the pop-up feedback and iterated again until the constraint verification is passed. This ensures that the final output 3D geometric model is fully compliant in terms of physical dimensions, and the electromagnetic simulation results have practical reference value. This achieves a strong binding between model geometric validity, simulation reliability, and iterative convergence.
[0078] (3) Output the derived parameters that satisfy the constraints to generate the 3D geometric model of the PCB transformer.
[0079] Specifically, the derived parameters that finally meet the conditions after constraint verification and iterative adjustment are written into the output parameter table; the derived parameters in the output parameter table, together with the original fixed variables and optimization variables, are passed to the geometric modeling module; the modeling script based on Python and pyAEDT is called to execute the drawing according to the geometric assembly order of magnetic core, PCB substrate, winding conductor, air gap and spacing; after the creation of all geometric elements is completed, a complete 3D geometric model of the PCB transformer is generated and exported in a file format that can be recognized by the simulation software.
[0080] By automatically comparing the calculated derived parameters with preset geometric constraints and intelligently adjusting and optimizing variables when parameters exceed the range, the process iterates repeatedly until all derived parameters meet the constraints. Finally, compliant parameters are output and a 3D model is generated. This achieves closed-loop self-correction of dimensional parameters during the modeling process, completely avoiding model generation failure or simulation invalidity caused by unreasonable geometric dimensions. It eliminates the tedious process of manual trial and error and repeated adjustments by designers, significantly improving the success rate of first-time model generation and geometric compliance, while ensuring the effectiveness and reliability of subsequent electromagnetic simulation and structural verification.
[0081] The automated transformer 3D modeling method provided in this embodiment abstracts the structural features of the transformer into multi-dimensional parameters such as the number of horizontal units, the number of vertical units, layer distribution coding, series-parallel coding, layer thickness coding, and the number of turns per layer. These parameters are systematically divided into fixed and optimized variables, achieving modular separation and precise management of design parameters. Based on this, derived parameters such as core height and structural spacing are automatically calculated, eliminating manual calculation errors. Finally, based on the Python and pyAEDT environment, a complete 3D model is generated with one click, strictly following the geometric assembly dependency order. This completely replaces the traditional manual drawing and repeated modification modeling method, significantly shortening the modeling cycle. It supports arbitrary expansion of core columns and horizontal / matrix array structures. The layer distribution coding flexibly configures the order and number of primary and secondary winding layers using "1" and "0". The series-parallel coding controls the winding connection state through coding bits. The layer thickness coding allows independent setting of the thickness of each layer, and the number of turns variable supports differentiated settings for each layer. One model can cover the needs of multiple PCB transformer specifications, exhibiting strong compatibility and versatility. Meanwhile, the optimization variables are given scanning attributes, which can automatically scan parameters in the simulation environment and quickly iterate the impact of core size, PCB thickness, air gap length, winding spacing, etc. on performance. After the derived parameters are calculated, they are automatically compared with the preset geometric constraints. If they exceed the range, the optimization variables are intelligently adjusted and recalculated until the constraints are met, forming a closed-loop self-correction. This avoids modeling failures caused by unreasonable geometric dimensions and improves the success rate of model generation and simulation effectiveness.
[0082] Corresponding to the aforementioned embodiment of an automated transformer 3D modeling method, this application also provides an embodiment of an automated transformer 3D modeling device.
[0083] Figure 2 This is a schematic diagram of the structure of Embodiment 2 of the automated transformer 3D modeling device provided in this application. Please refer to... Figure 2 The apparatus provided in this embodiment includes an acquisition module 210, a processing module 220, and a generation module 230;
[0084] The acquisition module 210 is used to acquire modeling parameters, which include at least the number of horizontal units, the number of vertical units, the layer distribution code, the serial-parallel code, the layer thickness code, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure.
[0085] The processing module 220 is used to divide the modeling parameters into fixed variables and optimization variables;
[0086] The processing module 220 is also used to calculate derived parameters based on the modeling parameters;
[0087] The generation module 230 is used to run code based on the Python and pyAEDT environment, read the modeling parameters and the derived parameters, determine the modeling execution order according to the geometric assembly logic, and generate a complete 3D geometric model of the PCB transformer.
[0088] The apparatus of this embodiment can be used to perform... Figure 1 The steps of the method embodiment shown are similar in principle and process, and will not be repeated here.
[0089] The specific implementation process of the functions and roles of each unit in the above device can be found in the implementation process of the corresponding steps in the above method, and will not be repeated here.
[0090] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to in the description of the method embodiments. The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this application according to actual needs. Those skilled in the art can understand and implement this without creative effort.
[0091] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.
Claims
1. An automated 3D modeling method for transformers, characterized in that, The method includes: Obtain modeling parameters, which include at least the number of transverse units, the number of longitudinal units, layer distribution coding, serial-parallel coding, layer thickness coding, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure; The modeling parameters are divided into fixed variables and optimized variables. Among them, the number of horizontal units, the number of vertical units, the layer distribution code, the serial-parallel code, and the layer thickness code are included in the fixed variable set, and the number of turns per layer of the primary side and the number of turns per layer of the secondary side are included in the optimized variable set. Simulation scan attribute identifiers are added to the optimized variables. Calculating derived parameters based on the modeling parameters; wherein, calculating derived parameters based on the modeling parameters includes: Obtain the core size, total PCB thickness, and air gap length from the modeling parameters; The initial value of the magnetic core height is calculated based on the magnetic core size, the total PCB thickness, and the air gap length; The initial value of the magnetic core height is matched and corrected with a preset step size to obtain the magnetic core height as a derived parameter; Compare the derived parameters with the preset geometric constraints; If the derived parameter exceeds the range of the constraint, adjust at least one parameter in the optimization variables and recalculate the derived parameter until the derived parameter satisfies the constraint. If the constraint is not satisfied after reaching the maximum number of iterations, stop the loop and do not use the derived parameters that do not currently satisfy the constraint in the formal 3D model of the simulation. Output the derived parameters that satisfy the constraint. The code runs on Python and pyAEDT environment, reads the modeling parameters and the derived parameters, determines the modeling execution order according to the geometric assembly logic, and generates a complete 3D geometric model of the PCB transformer. Specifically, the number of horizontal and vertical units is read and their product is calculated as the total number of core arrays, used to generate multi-unit matrices or horizontal arrays through a double-loop programmatic process during geometric modeling. The modeling code automatically parses the layer distribution code and the series-parallel code, generates the winding conductors of the corresponding layers bit by bit and assigns the correct primary and secondary side attributes, and automatically adds series or parallel electrical connections between the winding ports according to the coded bits. The air gap length parameter and winding spacing parameter in the modeling parameters are read, and an air gap is generated at a specified position in the core column through Boolean subtraction. An insulation spacing structure is generated between adjacent winding layers or between the winding and the core. Related components are merged to form a complete PCB transformer assembly, which is then exported as a 3D geometric model file that can be directly recognized by electromagnetic simulation software.
2. The method according to claim 1, characterized in that, The step of dividing the modeling parameters into fixed variables and optimization variables includes: Determine the basic structural parameters of the transformer; Based on the aforementioned basic structural parameters, the fixed variables and optimization variables in the modeling parameters are selected.
3. The method according to claim 1, characterized in that, The layer distribution encoding uses string encoding, where character 1 represents the primary winding and character 0 represents the secondary winding. The winding layer order and number of layers of the transformer are determined based on the string encoding.
4. The method according to claim 1, characterized in that, The series-parallel encoding controls the connection state of the windings through encoding bits.
5. The method according to claim 1, characterized in that, The number of turns in each layer of the primary winding is determined based on the variable number of turns in each layer of the primary winding, and the number of turns in each layer of the secondary winding is determined based on the variable number of turns in each layer of the secondary winding.
6. The method according to claim 1, characterized in that, The structural code, core array quantity, and winding turn count are determined based on the fixed variables, and the core size, PCB thickness, air gap length, and winding spacing are adjusted based on the optimized variables.
7. The method according to claim 1, characterized in that, The modeling execution order is determined according to the geometric assembly logic, including: Draw the magnetic core to determine the global spatial reference; Determine the PCB substrate based on the magnetic core window; The winding conductor is drawn on the PCB substrate, and an air gap structure and a spacing structure are generated on the magnetic core and the winding conductor, respectively.
8. An automated transformer 3D modeling device, characterized in that, The device includes an acquisition module, a processing module, and a generation module; The acquisition module is used to acquire modeling parameters, which include at least the number of horizontal units, the number of vertical units, the layer distribution code, the serial-parallel code, the layer thickness code, the number of turns per layer on the primary side, and the number of turns per layer on the secondary side of the magnetic core array structure. The processing module is used to divide the modeling parameters into fixed variables and optimized variables; wherein, the number of horizontal units, the number of vertical units, the layer distribution code, the serial-parallel code, and the layer thickness code are included in the fixed variable set, the number of turns per layer of the primary side and the number of turns per layer of the secondary side are included in the optimized variable set, and simulation scan attribute identifiers are added to the optimized variables; The processing module is further configured to calculate derived parameters based on the modeling parameters; wherein, calculating derived parameters based on the modeling parameters includes: Obtain the core size, total PCB thickness, and air gap length from the modeling parameters; The initial value of the magnetic core height is calculated based on the magnetic core size, the total PCB thickness, and the air gap length; The initial value of the magnetic core height is matched and corrected with a preset step size to obtain the magnetic core height as a derived parameter; Compare the derived parameters with the preset geometric constraints; If the derived parameter exceeds the range of the constraint, adjust at least one parameter in the optimization variables and recalculate the derived parameter until the derived parameter satisfies the constraint. If the constraint is not satisfied after reaching the maximum number of iterations, stop the loop and do not use the derived parameters that do not currently satisfy the constraint in the formal 3D model of the simulation. Output the derived parameters that satisfy the constraint. The generation module is used to run code based on Python and pyAEDT environment, read the modeling parameters and the derived parameters, determine the modeling execution order according to geometric assembly logic, and generate a complete 3D geometric model of PCB transformer. Specifically, it reads the number of horizontal units and the number of vertical units and calculates their product as the total number of core arrays, which is used to generate multi-unit matrices or horizontal arrays through a double-loop programmatic process during geometric modeling. After automatically parsing the layer distribution code and the series-parallel code, the modeling code generates the winding conductors of the corresponding layers bit by bit and assigns the correct primary and secondary side attributes. It automatically adds series or parallel electrical connections between winding ports according to the coded bits. It reads the air gap length parameter and winding spacing parameter from the modeling parameters, generates air gap gaps at specified positions in the core column through Boolean subtraction, generates insulation spacing structures between adjacent winding layers or between windings and the core, merges related components to form a complete PCB transformer assembly, and exports it as a three-dimensional geometric model file that can be directly recognized by electromagnetic simulation software.
Citation Information
Patent Citations
Transformer modeling method based on parametric design
CN122413688A
Fabrication trade-off based optimal synthesis of winding configurations for planar transformer in capacitor-inductor-inductor-capacitor (CLLC) direct current (DC)-DC converter
US20230387816A1