hi all ,,

i am using ade7880 for getting harmonic calculation.

I have connected with 3.5A, 400w and 0.5 power factor , when i am reading VTHD that is 225869. so now how to calculate total harmonic distortion with VTHD register value..

hi all ,,

i am using ade7880 for getting harmonic calculation.

I have connected with 3.5A, 400w and 0.5 power factor , when i am reading VTHD that is 225869. so now how to calculate total harmonic distortion with VTHD register value..

Hi kishore.r

Let us use the other thread to continue the discussion: http://ez.analog.com/message/127174

Dividing register value by 2^21, you will get VTHD ratio of 0.1077, which would correspond to 10.77% THD.

Regards

hmani

Hi kishore.r

Kindly continue the discussion only in one thread: http://ez.analog.com/message/127265#127265

I would also recommend not posting the same question on multiple threads.

Thanks!

Regards

hmani

hi hmani,

thank you for ur reply, now i have one another question ...

my total harmonic distortion is( VTHDN )=3.56% , if i am adding all 63 individual harmonic percentage is not equal to my total harmonic distortion. that both (total harmonic and individual harmonic of all 63 ) should be equal right?

why i am not getting equal?

Regards,

kishore

Hi kishore.r

I apologize for the delay in getting back to you on this question. We had a holiday shutdown during the past two weeks.

The formula for voltage signal's total harmonic distortion is :

where V is the RMS of the voltage signal over the entire frequency band- fundamental+ harmonics+ noise ( 3.3 KHz is -3dB bandwidth)

and V1 is the RMS of the fundamental frequency component (FVRMS)

The formula for harmonic distortion(HD) of a voltage harmonic component is : HXVHD= Vx/V1 (x=2,3,4,.....N)

where Vx is the RMS of the harmonic component (HXVRMS).

The relationship between THD and HD is :

So, if you add the squares of all harmonic distortion values (HXVHD) and take the square root of the sum, the answer would be closer to the THD value you get from the chip. Each of the harmonic results aren't taken at the same instant ( only 3 components can be taken at a time) and hence there might be certain discrepancies in the matching of these values. Also, the THD result shown is effectively THD + noise, as the 'V' value in it contains noise component as well. Finally, each measurement has a particular low value of error% associated with it. All these factors are responsible for the results not matching exactly with one another.

Regards

hmani

Hi kishore.r

V is the voltage RMS measurement available either in AVRMS,BVRMS and CVRMS registers, based on which phase you are looking at. But all this is done internally and the chip gives out the THD value through the VTHD register. Are you trying to verify the measurement or are you getting faulty results? If so, do express the register values you are seeing and I can help clarify the results.

Regards

hmani

Hi kishore.r

Below is an example experiment that I conducted:

Voltage signal applied Amplitude Fundamental - V1 FS/2= 353.55mVrms/2= 0.17677Vrms 3rd harmonic - V3 FS/10=353.55mVrms/10=0.035355Vrms 5th harmonic- V5 FS/10=353.55mVrms/10=0.035355Vrms 7th harmonic - V7 FS/10=353.55mVrms/10=0.035355Vrms Register Values read back HXVHD 0.200075 HYVHD 0.200046 HZVHD 0.200077 AVRMS 2032862 FVRMS 1920092 VTHD 0.346662 **Checking THD using applied signals:**Or in other words:

THD = sqrt(V3^2 + V5^2 + V7^2)/ V1 = 0.346410162 ( which is close to the register value read)

**Checking THD using HD results:**THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)= 0.346524478 ( which again matches with the read back THD value)

Also, VRMS/FVRMS register reading at full scale is : 3766572

The FVRMS register reading observed is 1920092, which is 1920092/3766572 of FS= 0.50977 of FS ( which is correct)

The AVRMS register reading observed is 2032862, which is 2032862/3766572 of FS= 0.539711 of FS.

If you compute VRMS by doing the sum of squares of V1,V3,V5 and V7 and then taking the square root of the result, you get 0.187082 Vrms which is 0.52915 of FS and hence correct as well)

Hope this clarifies your confusion! You can try a similar experiment to verify your results as well.

Regards

hmani

Hi hmani,

I have assigned HX=2,HY=3,and HZ=4 then the register reading is

Register Values HXVHD 0.071 HYVHD 0.467 HZVHD 0.046

VTHD 6.584

according to this formula THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)

(0.071^2+0.467^2+0.046+2)=0.4746 but is value is not related to my VTHD register (6.584)

pls tell me what is the reason i am not getting related out put?

Hi hmani,

I have assigned HX=2,HY=3,and HZ=4 then the register reading is

Register Values HXVHD 0.071 HYVHD 0.467 HZVHD 0.046

VTHD 6.584

according to this formula THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)

(0.071^2+0.467^2+0.046+2)=0.4746 but is value is not related to my VTHD register (6.584)

pls tell me what is the reason i am not getting related out put?

Hi hmani,

I have assigned HX=2,HY=3,and HZ=4 then the register reading is

Register Values HXVHD 0.071 HYVHD 0.467 HZVHD 0.046

VTHD 6.584

according to this formula THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)

(0.071^2+0.467^2+0.046+2)=0.4746 but is value is not related to my VTHD register (6.584)

pls tell me what is the reason i am not getting related out put?

Hi hmani,

I have assigned HX=2,HY=3,and HZ=4 then the register reading is

Register Values HXVHD 0.071 HYVHD 0.467 HZVHD 0.046

VTHD 6.584

according to this formula THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)

(0.071^2+0.467^2+0.046+2)=0.4746 but is value is not related to my VTHD register (6.584)

pls tell me what is the reason i am not getting related out put?

Hi kishore.r

Can you read the HD values for all harmonics within the bandwidth and not just 2,3 and 4? May be you have other harmonics like the 5th or 7th or higher, which is causing the THD to be higher. You can only read three HD values at a time. So, try to measure the HD for all harmonics in sets of 3. Try to monitor the VTHD reading during each set to make sure that the THD value is in the same range.

Regards

hmani

Hi hmani,

Now i am chacking Phase A only so i set,

HCONFIG=0x00,STATUS0=0x00800000

hx=2,hy=3and hz=4 after setting these register i made 600ms delay and i am reading HXVHD,HYVHD,HZVHD . same likewise every 600ms i am changing hx, hy and hz value up to 63 then the register value is given below...

HXVHD 162 ( hear 162 is register value and the harmonic is (162/(2^21))*100=0.007)

2 Order harmonic is 0.007 (162/(2^21))*100=0.007)

HYVHD 486

3 Order harmonic is 0.023 (468/(2^21))*100=0.023)

HZVHD 125

4 Order harmonic is 0.005 (125/(2^21))*100=0.005)

VTHD 71477

Total voltage waveform harmonic distortion is 3.408

HXVHD 2727

5 Order harmonic is 0.130

HYVHD 14531

6 Order harmonic is 0.692

HZVHD 2205

7 Order harmonic is 0.105

VTHD 67311

Total voltage waveform harmonic distortion is 3.209

HXVHD 50657

8 Order harmonic is 2.415

HYVHD 3936

9 Order harmonic is 0.187

HZVHD 17384<LF>

10 Order harmonic is 0.828

VTHD 67737

Total voltage waveform harmonic distortion is 3.229

HXVHD 1834

11 Order harmonic is 0.087

HYVHD 7029

12 Order harmonic is 0.335

HZVHD 2291

13 Order harmonic is 0.109

VTHD 73117

Total voltage waveform harmonic distortion is 3.486

HXVHD 1602

14 Order harmonic is 0.076

HYVHD 1007

15 Order harmonic is 0.048

HZVHD 2481

16 Order harmonic is 0.118

VTHD 69812

Total voltage waveform harmonic distortion is 3.328

HXVHD 1341

17 Order harmonic is 0.063

HYVHD 2101

18 Order harmonic is 0.100

HZVHD 99

19 Order harmonic is 0.004

VTHD 64465

Total voltage waveform harmonic distortion is 3.073

HXVHD 3394

20 Order harmonic is 0.161

HYVHD 1272

21 Order harmonic is 0.060

HZVHD 3332

22 Order harmonic is 0.158

VTHD 73239

Total voltage waveform harmonic distortion is 3.492

HXVHD 806

23 Order harmonic is 0.038

HYVHD 1272

24 Order harmonic is 0.060

HZVHD 1596

25 Order harmonic is 0.076

VTHD 72744

Total voltage waveform harmonic distortion is 3.468

HXVHD 1858

26 Order harmonic is 0.088

HYVHD 836

27 Order harmonic is 0.039

HZVHD 1968

28 Order harmonic is 0.093

VTHD 71931

Total voltage waveform harmonic distortion is 3.429

HXVHD 1203

29 Order harmonic is 0.057

HYVHD 4742

30 Order harmonic is 0.226

HZVHD 519

31 Order harmonic is 0.024

VTHD 72170

Total voltage waveform harmonic distortion is 3.441

HXVHD 6345

32 Order harmonic is 0.302

HYVHD 1088

33 Order harmonic is 0.051

HZVHD 6377

34 Order harmonic is 0.304

VTHD 74950

Total voltage waveform harmonic distortion is 3.573

HXVHD 985

35 Order harmonic is 0.046

HYVHD 6172

36 Order harmonic is 0.294

HZVHD 883

37 Order harmonic is 0.042

VTHD 71096

Total voltage waveform harmonic distortion is 3.390

HXVHD 6799

38 Order harmonic is 0.324

HYVHD 1026

39 Order harmonic is 0.048

HZVHD 6657

40 Order harmonic is 0.317

VTHD 72389

Total voltage waveform harmonic distortion is 3.451

HXVHD 611

41 Order harmonic is 0.029

HYVHD 6276

42 Order harmonic is 0.299

HZVHD 790

43 Order harmonic is 0.037

VTHD 73321

Total voltage waveform harmonic distortion is 3.496

HXVHD 5858

44 Order harmonic is 0.279

HYVHD 254

45 Order harmonic is 0.012

HZVHD 4122

46 Order harmonic is 0.196

VTHD 72176

Total voltage waveform harmonic distortion is 3.441

HXVHD 558

47 Order harmonic is 0.026

HYVHD 2664

48 Order harmonic is 0.127

HZVHD 267

49 Order harmonic is 0.012

VTHD 70509

Total voltage waveform harmonic distortion is 3.362

HXVHD 1299

50 Order harmonic is 0.061

HYVHD 363

51 Order harmonic is 0.017

HZVHD 985

52 Order harmonic is 0.046

VTHD 70944

Total voltage waveform harmonic distortion is 3.382

HXVHD 109

53 Order harmonic is 0.005

HYVHD 1446

54 Order harmonic is 0.068

HZVHD 327

55 Order harmonic is 0.015

VTHD 76975

Total voltage waveform harmonic distortion is 3.670

HXVHD 1299

56 Order harmonic is 0.061

HYVHD 112

57 Order harmonic is 0.005

HZVHD 1203

58 Order harmonic is 0.057

VTHD 74679

Total voltage waveform harmonic distortion is 3.560

HXVHD 36

59 Order harmonic is 0.001

HYVHD 873

60 Order harmonic is 0.041

HZVHD 89

61 Order harmonic is 0.004

VTHD 72608

Total voltage waveform harmonic distortion is 3.462

HXVHD 648

62 Order harmonic is 0.030

HYVHD 56

63 Order harmonic is 0.002

HZVHD 324

VTHD 72608

Total voltage waveform harmonic distortion is 3.462

Now according to this formula THD = sqrt(HXVHD^2+HYVHD^2+HZVHD^2)

i am not getting related value. So please tell me where i made a mistake and pls give me a example for verifying total harmonic distortion with these values...

Hi kishore.r

Here is the calculation that I worked out:

harmonic HD-measured HD^2 THD-calculated THD-measured THD-avg 2 0.007 0.000049 2.845315097 3.408 3.419619048 3 0.023 0.000529 3.209 4 0.005 0.000025 3.229 5 0.13 0.0169 3.486 6 0.692 0.478864 3.328 7 0.105 0.011025 3.073 8 2.415 5.832225 3.492 9 0.187 0.034969 3.468 10 0.828 0.685584 3.429 11 0.087 0.007569 3.441 12 0.335 0.112225 3.573 13 0.109 0.011881 3.39 14 0.076 0.005776 3.451 15 0.048 0.002304 3.496 16 0.118 0.013924 3.441 17 0.063 0.003969 3.362 18 0.1 0.01 3.382 19 0.004 0.000016 3.67 20 0.161 0.025921 3.56 21 0.06 0.0036 3.462 22 0.158 0.024964 3.462 23 0.038 0.001444 24 0.06 0.0036 25 0.076 0.005776 26 0.088 0.007744 27 0.039 0.001521 28 0.093 0.008649 29 0.057 0.003249 30 0.226 0.051076 31 0.024 0.000576 32 0.302 0.091204 33 0.051 0.002601 34 0.304 0.092416 35 0.046 0.002116 36 0.294 0.086436 37 0.042 0.001764 38 0.324 0.104976 39 0.048 0.002304 40 0.317 0.100489 41 0.029 0.000841 42 0.299 0.089401 43 0.037 0.001369 44 0.279 0.077841 45 0.012 0.000144 46 0.196 0.038416 47 0.026 0.000676 48 0.127 0.016129 49 0.012 0.000144 50 0.061 0.003721 51 0.017 0.000289 52 0.046 0.002116 53 0.005 0.000025 54 0.068 0.004624 55 0.015 0.000225 56 0.061 0.003721 57 0.005 0.000025 58 0.057 0.003249 59 0.001 0.000001 60 0.041 0.001681 61 0.004 0.000016 62 0.03 0.0009 63 0.002 0.000004 The THD value that I calculated from the observed HD values is 2.845315097. I have also averaged the THD values that you observed multiple times and that is 3.419619048. The difference that you observe between these numbers is due to the noise that I was referring to, in the earlier post. The THD register value takes into account, the distortion due to harmonic frequencies and noise as well. We must also consider the fact that there will be some error associated with each register read.

Let me know if this clarifies your doubts. If you still have concerns, let me know more about your project and what you are trying to establish. That might enable me to help you better.

Regards

hmani

hi hmani,

hx=2,hy=3and hz=4 after setting these register i made 600ms delay and i am reading HXVHD,HYVHD,HZVHD

HXVRMS,HYVRMS,HZVRMS

upto 63 harmonic.

harmonic calculation

HXVHD 85->(register value)

2 Order harmonic is = 0.004

HXVRMS =122

V2= 0.010

HYVHD 547

3 Order harmonic is = 0.026

HYVRMS =653

V3= 0.058

HZVHD 161

4 Order harmonic is = 0.007

HZVRMS =244

V4= 0.021

HXVHD 2513

5 Order harmonic is = 0.119

HXVRMS =3779

V5= 0.337

HYVHD 11837

6 Order harmonic is = 0.564

HYVRMS =15384

V6= 1.372

HZVHD 1448

7 Order harmonic is = 0.069

HZVRMS =1608

V7 = 0.143

HXVHD 57756

8 Order harmonic is = 2.754

HXVRMS =73547

V8= 6.562

HYVHD 3321

9 Order harmonic is = 0.158

HYVRMS =4312

V9=0.384

HZVHD 9385

10 Order harmonic is = 0.447

HZVRMS =11937

V10= 1.065

HXVHD 1366

11 Order harmonic is = 0.065

HXVRMS =1829

V11= 0.163

HYVHD 5767

12 Order harmonic is = 0.274

HYVRMS =7341

V12= 0.655<LF>

HZVHD 1756

13 Order harmonic is = 0.083

HZVRMS =2192

V13= 0.195

HXVHD 2271

14 Order harmonic is = 0.108

HXVRMS =2901

V14= 0.258

HYVHD 876

15 Order harmonic is = 0.041

HYVRMS =1139

V15= 0.101

HZVHD 2693

16 Order harmonic is = 0.128

HZVRMS =3462

V16= 0.308

HXVHD 1376

17 Order harmonic is = 0.065

HXVRMS =1782

V17= 0.158

HYVHD 2247

18 Order harmonic is = 0.107

HYVRMS =2840

V18= 0.253

HZVHD 286

19 Order harmonic is = 0.013

HZVRMS =315

V19= 0.028

HXVHD 4321

20 Order harmonic is = 0.206

HXVRMS =5532

V20= 0.493

HYVHD 1750

21 Order harmonic is = 0.083

HYVRMS =2222

V21= 0.198

HZVHD 4113

22 Order harmonic is = 0.196

HZVRMS =5077

V22= 0.452

HXVHD 659

23 Order harmonic is = 0.031

HXVRMS =840

V23= 0.074

HYVHD 1537

24 Order harmonic is = 0.073

HYVRMS =2013

V24= 0.179

HZVHD 1807

25 Order harmonic is = 0.086

HZVRMS =2359

V25= 0.210

HXVHD 1445

26 Order harmonic is = 0.068

HXVRMS =1896

V26= 0.169

HYVHD 1216

27 Order harmonic is = 0.057

HYVRMS =1377

V27= 0.122

HZVHD 4620

28 Order harmonic is = 0.220

HZVRMS =5928

V28= 0.528

HXVHD 1407

29 Order harmonic is = 0.067

HXVRMS =1911

V29= 0.170

HYVHD 4241

30 Order harmonic is = 0.202

HYVRMS =5581

V30= 0.497

HZVHD 923

31 Order harmonic is = 0.044

HZVRMS =1154

V31= 0.102

HXVHD 6773

32 Order harmonic is = 0.322

HXVRMS =8735

V32= 0.779

HYVHD 1209

33 Order harmonic is = 0.057

HYVRMS =1554

V33= 0.138

HZVHD 4909

34 Order harmonic is = 0.234

HZVRMS =6115

V34= 0.545

HXVHD 367

35 Order harmonic is = 0.017

HXVRMS =443

V35= 0.039

HYVHD 4238

36 Order harmonic is = 0.202

HYVRMS =5453

V36= 0.486

HZVHD 1027

37 Order harmonic is = 0.048

HZVRMS =1092

V37= 0.097

HXVHD 4966

38 Order harmonic is = 0.236

HXVRMS =6372

V38= 0.568

HYVHD 282

39 Order harmonic is = 0.013

HYVRMS =496

V39= 0.044

HZVHD 7292

40 Order harmonic is = 0.347

HZVRMS =9132

V40= 0.814

HXVHD 947

41 Order harmonic is = 0.045

HXVRMS =1145

V41= 0.102

HYVHD 6651

42 Order harmonic is = 0.317

HYVRMS =8588

V42= 0.766

HZVHD 448

43 Order harmonic is = 0.021

HZVRMS =550

V43= 0.049

HXVHD 5196

44 Order harmonic is = 0.247

HXVRMS =6591

V44= 0.588

HYVHD 545

45 Order harmonic is = 0.025

HYVRMS =879

V45= 0.078

HZVHD 4114

46 Order harmonic is = 0.196

HZVRMS =5177

V46= 0.461

HXVHD 178

47 Order harmonic is = 0.008

HXVRMS =155

V47= 0.013

HYVHD 2712

48 Order harmonic is = 0.129

HYVRMS =3567

V48= 0.318

HZVHD 219

49 Order harmonic is = 0.010

HZVRMS =223

V49= 0.019

HXVHD 1958

50 Order harmonic is = 0.093

HXVRMS =2541

V50= 0.226

HYVHD 134

51 Order harmonic is = 0.006

HYVRMS =265

V51= 0.023

HZVHD 1751

52 Order harmonic is = 0.083

HZVRMS =2156

V52= 0.192

HXVHD 131

53 Order harmonic is = 0.006

HXVRMS =202

V53= 0.018

HYVHD 1150

54 Order harmonic is = 0.054

HYVRMS =1441

V55= 0.128

HZVHD 191

55 Order harmonic is = 0.009

HZVRMS =286

V56= 0.025

HXVHD 1439

56 Order harmonic is = 0.068

HXVRMS =1878

V56= 0.167

HYVHD 257

57 Order harmonic is = 0.012

HYVRMS =325

V57= 0.028

HZVHD 1056

58 Order harmonic is = 0.050

HZVRMS =1321

V58= 0.117

HXVHD 53

59 Order harmonic is = 0.002

HXVRMS =113

V59= 0.010

HYVHD 953

60 Order harmonic is = 0.045

HYVRMS =1225

V60= 0.109

HZVHD 134

61 Order harmonic is = 0.006

HZVRMS =133

V61= 0.011

HXVHD 808

62 Order harmonic is = 0.038

HXVRMS =1069

V62= 0.095

HYVHD 59

63 Order harmonic is = 0.002

HYVRMS =81

V63= 0.007

VTHD register value =66407 --> Total voltage harmonic distortion is 3.166

harmonic voltage Vh=(V2+V3+V4...V63) =22.357

THD=(Vh/V1)X100

So according to this formula

THD=(22.357/238.277)X100 = 9.3

but VTHD register is giving 3.166

same like this another set of values i have readed

VTHD 208331 ->> Total voltage harmonic distortion is 9.933

THD=(11.386/236.240)X100 =4.8

THD register value THD from VRMS harmonic

3.166 9.3

9.933 4.8

I am not getting equal value of THD register value and THD from VRMS harmonic .

hi mani ,

I am checking whether the VTHDN register value is correct or not , for that i have calculated THD using HXVRMS HYVRMS and HZVRMS regisger and HXVHD HYVHD and HZVHD these register i have calculated THD value . VTHDN register reading and calculated THD readings are given below.

7.014 2.648 2.634

6.769 2.617 2.601

i got this answer . The two formula readings are getting same value but the VTHDN register reading is not related to the any one of the formula result. if VTHDN register reading also getting related to 2.648 then my VTHDN register reading is correct, but it is not coming in the correct way pls tell me why the VTHDN register reading is getting more difference ?

Regards,

Kishore R

Hi hmani,

I have checked individual harmonic distortion of upto 63. like this

HDx=Vx/V1;

according to this formula i am getting

Vx/V1 HXVTHD,HYVTHD,HZVTHD

HD2 0.000 (this is not in %) HXVRMS= 0.000 (this is not in %)

HD3 0.000 HYVRMS= 0.000

HD4 0.0017 HZVRMS= 0.002

HD5 0.00404 HXVRMS= 0.004

HD6 0.0045 HYVRMS= 0.00483

HD7 0.000291 HZVRMS 0.00029

HD8 0.0168 HXVRMS=0.0177

HD9 0.00033 HYVRMS =0.00036

HD10 0.00740 HZVRMS= 0.0077

like this the individual harmonic distortion are getting almost equal value upto 63.

but when i am verifying total harmonic distortion

using this formula i am getting 2.013% but the VTHDN register is giving 12.435%

and also using this formula i am getting 2.012% then why the VTHDN register is not equal to 2.013%?

Regards,

Kishore.R

Hi kishore.r

I do not agree with your THD formula of:

harmonic voltage Vh=(V2+V3+V4...V63)

THD=(Vh/V1)X100

The correct one is the following:

So, the numerator must be the square root of sum of squares of the RMS of the harmonic components from 2nd to 63rd harmonics.

Based on your register measurements reported at first, the THD register value made sense with the HD register values. But the values that your are now reporting seems to suggest that there is some disconnect. I believe that the best way to check the correctness of these computations is to apply known accurate signals at fundamental and harmonic frequencies and then verify the register measurements. If your signal is noisy, changing and unknown, verifying the harmonic engine measurements, based on that, is difficult. Do you have an accurate source to do that? Or if you have another measurement instrument/setup that can show you the HD and THD values over the same bandwidth accurately, you can compare the results with that reported by ADE7880.

Regards

hmani

Hi kishore.r

Let us use the other thread to continue the discussion: http://ez.analog.com/message/127174

Dividing register value by 2^21, you will get VTHD ratio of 0.1077, which would correspond to 10.77% THD.

Regards

hmani