Build a small inverter-model comparison harness建立一个小型逆变器模型对比框架
Start from simulation/tutorials_ep6_svpwm.py or a copy of it. Your goal is to compare how the motor input changes when the inverter is represented at different levels of detail.
从 simulation/tutorials_ep6_svpwm.py 或它的副本开始。你的目标是比较:当逆变器用不同详细程度表示时,电机输入会怎样改变。
Three required inverter models三种必做逆变器模型
Mode A: ideal voltage source模式 A:理想电压源
Feed the commanded $\alpha\beta$ or phase voltage directly into the machine model after normal voltage limiting. This is the fast control-design baseline.在正常电压限幅之后,把控制器指令的 $\alpha\beta$ 或相电压直接送入电机模型。这是快速控制设计基线。
Mode B: average inverter模式 B:平均逆变器
Use duty ratios to compute $\bar u_{xG}=d_xV_{dc}$, then subtract the neutral potential to obtain $\bar u_{xn}$.用占空比计算 $\bar u_{xG}=d_xV_{dc}$,然后减去中性点电位得到 $\bar u_{xn}$。
Mode C: switching inverter模式 C:开关逆变器
Use actual switching states from the PWM carrier comparison and compute $u_{xG}=S_xV_{dc}$ at the machine integration time step.使用 PWM 载波比较得到的实际开关状态,并在电机积分步长上计算 $u_{xG}=S_xV_{dc}$。
Bonus: dead-time model加分:死区模型
Add a simple current-sign-dependent voltage error $\Delta u_x\approx-\operatorname{sgn}(i_x)t_{dead}V_{dc}/T_{pwm}$ and compare it with Mode B or Mode C.加入一个简单的电流方向相关电压误差 $\Delta u_x\approx-\operatorname{sgn}(i_x)t_{dead}V_{dc}/T_{pwm}$,并与模式 B 或 C 对比。
Signals your simulation must log仿真必须记录的信号
| Signal group信号组 | Required examples至少包含 | Purpose用途 |
|---|---|---|
| Command voltage指令电压 | u_alpha*, u_beta* or u_a*, u_b*, u_c* |
Shows what the controller wanted.说明控制器想要什么。 |
| Duty ratios占空比 | T_a, T_b, T_c |
Connects SVPWM output to inverter model input.连接 SVPWM 输出与逆变器模型输入。 |
| Terminal potentials端电位 | u_aG, u_bG, u_cG, u_nG |
Separates bus-referenced voltages from winding voltages.区分母线参考电压与绕组电压。 |
| Winding voltage and current绕组电压与电流 | u_an, u_bn, i_a, i_b, i_c |
Shows what the machine dynamics actually receive.说明电机动态真正接收了什么。 |
Five required figures5 张必做图
Model comparison overview模型对比总览
Overlay one representative voltage signal from the ideal, average, and switching modes over the same time window.在同一个时间窗口中叠加理想、平均、开关三种模式下的一个代表性电压信号。
PWM-period zoomPWM 周期放大图
Zoom into several PWM periods and show switching terminal voltage plus its average value.放大几个 PWM 周期,展示开关端电压及其平均值。
Common-mode voltage共模电压
Plot $u_{nG}$ or an explicitly defined common-mode voltage for the average and switching models.画出平均模型与开关模型下的 $u_{nG}$ 或你明确定义的共模电压。
Current ripple comparison电流纹波对比
Compare current ripple between at least two models. Use the same operating point and the same axis scale.比较至少两种模型下的电流纹波。必须使用相同工况和相同坐标尺度。
Error or delay visualization误差或延迟可视化
Plot commanded voltage minus realized average voltage, or show the time shift between command update and voltage realization.画出指令电压减去实际平均电压,或展示指令更新与电压实现之间的时间偏移。
Questions your report must answer报告必须回答的问题
For your chosen operating point, where do the ideal and average inverter models agree, and where do they disagree?在你选择的工况下,理想模型和平均逆变器模型在哪些地方一致?在哪些地方不一致?
Why does the switching model show information that is invisible in the average model?为什么开关模型能显示平均模型中不可见的信息?
How did you compute $u_{nG}$ and winding voltage from terminal potentials?你如何从端电位计算 $u_{nG}$ 和绕组电压?
What changes when you increase or decrease MACHINE_SIMULATIONs_PER_SAMPLING_PERIOD?增大或减小 MACHINE_SIMULATIONs_PER_SAMPLING_PERIOD 时,结果有什么变化?
Which model would you use for current-loop controller design, and which model would you use for PWM waveform debugging?你会用哪种模型做电流环控制器设计?又会用哪种模型调试 PWM 波形?
If you implemented the dead-time bonus, how does its voltage error depend on current direction?如果你实现了死区加分项,它的电压误差如何依赖电流方向?
Suggested submission structure建议提交结构
PDF outlinePDF 提纲
- State the base script and the operating point.说明基础脚本和所选工况。
- Define the three inverter models you implemented.定义你实现的三种逆变器模型。
- List logged signals and sign conventions.列出记录信号和符号约定。
- Show F1-F5 and answer Q1-Q6.展示 F1-F5,并回答 Q1-Q6。
- Conclude which model is appropriate for which engineering question.总结不同工程问题适合哪一级模型。