# Calculating active and reactive power from phasor measurements in openhistorian

**URL:** <http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030>\
**Category:** GPA Products\
**Created:** [April 10, 2022, 6:42pm UTC](http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030 "2022-04-10T18:42:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hasalaid](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/hasalaid/32/993_2.png) [@hasalaid](http://discussions.gridprotectionalliance.org/u/hasalaid)\
**Post date:** [April 10, 2022, 6:42pm UTC](http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030/1 "2022-04-10T18:42:27Z")

</div>

Hi,  
I have Current and voltage phasor values streamed into openhistorian. I would like to calculate the active power and reactive power to restream via a TCP socket server and also display the power and reactive power in grafana. Can someone advise how I can do that?  
 ![image](http://gridbits.gridprotectionalliance.org/uploads/default/original/1X/cc7e560a528b859257b07be8e074072c2243419d.png)

 ![image](http://gridbits.gridprotectionalliance.org/uploads/default/original/1X/8b2906fdb01a026fe25c3b1c3f8ad6df56866e28.png)  
 ![image](http://gridbits.gridprotectionalliance.org/uploads/default/original/1X/82fa1782b125d876fcf8af9b66888b456b631690.png)

---

<div class="post-metadata">

**Author:** ![ritchiecarroll](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/ritchiecarroll/32/2_2.png) [@ritchiecarroll](http://discussions.gridprotectionalliance.org/u/ritchiecarroll)\
**Post date:** [April 11, 2022, 1:40pm UTC](http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030/2 "2022-04-11T13:40:38Z")

</div>

The easiest way is to go into the web interface, i.e., [http://localhost:8180/](http://localhost:8180/), and click on “Browse Devices”. Then click on the device for which you want power calculations, e.g., “RIGGS\_HALL”.

On this “New Device Commissioning Wizard” screen, select the voltage phasors that are associated with the current phasors - a requirement for power calculations.

Then under the “Tag Template” dropdown, select either “Single Phase Power Calculations” or “Three Phase Power Calculations”, depending on your need. Note that 3-phase power calculations include 1-phase power calculations for each phase, plus a 3-phase summary result.

Finally, click on “Save Device” and the power calculations measurements will now exist.

You can stream these power calculation measurements to other systems (e.g., using STTP over TCP), visualize them Grafana, etc.

Hope that helps.

Thanks,  
Ritchie

---

<div class="post-metadata">

**Author:** ![hasalaid](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/hasalaid/32/993_2.png) [@hasalaid](http://discussions.gridprotectionalliance.org/u/hasalaid)\
**Post date:** [April 13, 2022, 10:49pm UTC](http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030/3 "2022-04-13T22:49:02Z")

</div>

Thanks, Ritchie! It worked.

One more quick question but relating to grafana connected directly via openhistorian;

I can access the grafana server from a remote PC. However, it only allows for admin login.  
The grafana dashboard I want to display on the remote screen is on my windows authenticated (comes from openhistorian directly) grafana setup. When I am logging into the remote PC, but only have web browser access, how can I get access to the dashboard?

---

<div class="post-metadata">

**Author:** ![ritchiecarroll](http://discussions.gridprotectionalliance.org/user_avatar/discussions.gridprotectionalliance.org/ritchiecarroll/32/2_2.png) [@ritchiecarroll](http://discussions.gridprotectionalliance.org/u/ritchiecarroll)\
**Post date:** [April 13, 2022, 11:08pm UTC](http://discussions.gridprotectionalliance.org/t/calculating-active-and-reactive-power-from-phasor-measurements-in-openhistorian/1030/4 "2022-04-13T23:08:01Z")

</div>

You can use your local machine authentication, it will be in the form of `DOMAINNAME\USERNAME`, where `DOMAINNAME = COMPUTERNAME` for local accounts - or - you can just a period for short instead, e.g., `.\USERNAME` - then enter your current password. For example, if you are running as a local user and the openPDC admin user is a local account called `john`, then enter user name as `.\john` then your normal password. From a remote machine, it may be necessary to enter the full domain or computer name prefix instead of a period. Also, you will need to _uncheck_ “Use Integrated Windows Authentication” in order to enter a user name and password.

Once logged in you can navigate to `Settings > Users` on the main menu to add other users, including database users. Make sure to set the desired user role after adding the user. For Grafana read-only access, set the role to `Viewer`.

Hope that helps.

Thanks,  
Ritchie
