Under the mask for BLDC (Brushless DC Motor), there is a resistor and a variable inductor. How can I calculate the value? I’ve been using the exported data csv to calculate…however I am unsure on what formula to follow to determine R and L in a BLDC machine.

Also, whats the correlation of dl/dt and the fixed constant L?

You provide the resistance value directly in the block’s mask and it is fixed. The inductance is angle dependent and dynamically calculated, along with the derivative of the inductance. Are you just trying to know what values are calculated during the simulation? You can break the library link of the BLDC block and attach a Scope block to the control signal feeding the input to the Variable Inductor to see the vectorized magnitudes over time.

The voltage across a variable inductor is determined by: v = L*di/dt + i*dL/dt. This comes from applying the chain rule for d(L(t)*i(t))/dt. Therefore we provide the two inputs into the variable inductor component to describe its complete behavior. You can also read the block documentation for the BLDC and the Variable Inductor.

Does this answer your questions?

Thanks for replying Kris, it helped me out a lot. I do have another question though, in the parameters for the BLDC, there are 2 back EMG shape coefficients Kcn and Ksn. They are sort of arranged in a weird way, like a matrix? (correct me if I’m wrong) Anyways, I would like to kow how the EMF is being calculated via the formula, and how should one utilise these inputs during calculation. Maybe an example showing how the EMF is calculated would be helpful!

Hello, yes, we accept a vectorized input for the back EMF shape coefficients. You are able to look under the mask of the machine in the same way as you would monitor the inductance value and see how and where the Kc and Kn values are implemented. In this case they are assigned to a Fourier Series block with the angle input as shown in the attached screenshot:

After that calculation they are multiplied with the magnitude of the mechanical speed to get the EMF. Is that now more clear?

Thanks for the reply again Kris. However, I am still not quite sure about how the output of the fourier series would look like. Could you maybe show me an example of a calculation for the fourier series, with the corresponding coefficients a0=0, an=Kc, bn=Ks. I’d like to see some equations and how it computes to the output.

When I checked under the BLDC parameters, I noticed that the coefficients for Ksn and Kcn looked like this:

ksn: 0.4*24/pi^2*[1/2 0 1/9 0 1/50 0 -1/98 0 -1/81 0 -1/242]

Kcn: [0 0 0 0 0 0 0 0 0 0 0]

May I know why they are like this?

I’d also like to know how to calculate phasor difference between Is and Vs. (it’s in the jpeg attached below)

Once again thank so much for your help, I really appreciate it.

> I’d like to see some equations and how it computes to the output.

The Fourier Series block is part of the PLECS library. See the PLECS documentation for the component, copied below, for the equations. You can always place it in your own model to explore further.

> May I know why they are like this?

The exact coefficients are simply example values that give a quasi-trapezoidal waveshape. The values are all functions of sin(theta_m) to define a convention such that the peak back EMF is when the rotor is 90 degrees out of alignment with the phase A winding.

> I’d also like to know how to calculate phasor difference between Is and Vs. (it’s in the jpeg attached below)

The phasor value is only valid at one particular frequency. You can use the “Fourier Transform” block to extract the magnitude and phase values of your BEMF and current waveforms at a given frequency and compute the angle from there.