Wrong Allocated Power calculation for Three-phase Power Feed #6142

Closed
opened 2025-12-29 19:37:17 +01:00 by adam · 5 comments
Owner

Originally created by @svoropaev on GitHub (Feb 24, 2022).

NetBox version

3.1.8

Python version

3.9

Steps to Reproduce

Add any Three-phase Power Feed with any Voltage and Amperage.
Connect it to any Power Panel and power consumed device to trigger Utilization (Allocated) power calculation.

Expected Behavior

For 3 phase power source which is actually 5 pin socket widely used in Data Centers (example: 56P532) there are 3 pins are 3 phase, 1 pin is zero and one pin is ground.
Total power of 5 pin/3 phase power line should be not kva * 1.732 but kva * 3.
Formula kva * 1.732 is valid for 3 pin socket (which is actually 2 phase and 1 zero, not 3 phase).

def save(self, *args, **kwargs):

    # Cache the available_power property on the instance
    kva = abs(self.voltage) * self.amperage * (self.max_utilization / 100)
    if self.phase == PowerFeedPhaseChoices.PHASE_3PHASE:
        self.available_power = round(kva * 3)   <<<<<<<<<<<< change is here
    else:
        self.available_power = round(kva)

    super().save(*args, **kwargs)

Possible fix would be an additional Phase setting for Characteristics of Power Panel. Like as "DC 3 phase". Or change it to

  • 1 phase
  • 2 phase
  • 3 phase

Observed Behavior

def save(self, *args, **kwargs):

    # Cache the available_power property on the instance
    kva = abs(self.voltage) * self.amperage * (self.max_utilization / 100)
    if self.phase == PowerFeedPhaseChoices.PHASE_3PHASE:
        self.available_power = round(kva * 1.732).   <<<<<<<<<<<< **1.732 is a square root of 3.** 
    else:
        self.available_power = round(kva)

    super().save(*args, **kwargs)
Originally created by @svoropaev on GitHub (Feb 24, 2022). ### NetBox version 3.1.8 ### Python version 3.9 ### Steps to Reproduce Add any Three-phase Power Feed with any Voltage and Amperage. Connect it to any Power Panel and power consumed device to trigger Utilization (Allocated) power calculation. ### Expected Behavior For 3 phase power source which is actually 5 pin socket widely used in Data Centers (example: 56P532) there are 3 pins are 3 phase, 1 pin is zero and one pin is ground. Total power of 5 pin/3 phase power line should be not kva * 1.732 but kva * 3. Formula kva * 1.732 is valid for 3 pin socket (which is actually 2 phase and 1 zero, not 3 phase). def save(self, *args, **kwargs): # Cache the available_power property on the instance kva = abs(self.voltage) * self.amperage * (self.max_utilization / 100) if self.phase == PowerFeedPhaseChoices.PHASE_3PHASE: self.available_power = round(kva * 3) <<<<<<<<<<<< change is here else: self.available_power = round(kva) super().save(*args, **kwargs) Possible fix would be an additional Phase setting for Characteristics of Power Panel. Like as "DC 3 phase". Or change it to - 1 phase - 2 phase - 3 phase ### Observed Behavior def save(self, *args, **kwargs): # Cache the available_power property on the instance kva = abs(self.voltage) * self.amperage * (self.max_utilization / 100) if self.phase == PowerFeedPhaseChoices.PHASE_3PHASE: self.available_power = round(kva * 1.732). <<<<<<<<<<<< **1.732 is a square root of 3.** else: self.available_power = round(kva) super().save(*args, **kwargs)
adam added the type: bug label 2025-12-29 19:37:17 +01:00
adam closed this issue 2025-12-29 19:37:17 +01:00
Author
Owner

@jeremystretch commented on GitHub (Mar 1, 2022):

Add any Three-phase Power Feed with any Voltage and Amperage.

Please provide a specific example, including the perceived and expected utilization calculations.

@jeremystretch commented on GitHub (Mar 1, 2022): > Add any Three-phase Power Feed with any Voltage and Amperage. Please provide a specific example, including the perceived and expected utilization calculations.
Author
Owner

@svoropaev commented on GitHub (Mar 7, 2022):

Add any Three-phase Power Feed with any Voltage and Amperage.

Please provide a specific example, including the perceived and expected utilization calculations.

As you can see bellow Voltage=230 and Amperage=32 with Three-phase gives Utilization=12748VA. It is not right value.

image

The right Value should be Utilization=22080VA
image

@svoropaev commented on GitHub (Mar 7, 2022): > > Add any Three-phase Power Feed with any Voltage and Amperage. > > Please provide a specific example, including the perceived and expected utilization calculations. As you can see bellow Voltage=230 and Amperage=32 with Three-phase gives Utilization=12748VA. It is not right value. ![image](https://user-images.githubusercontent.com/94539620/157012166-fc080312-dcc7-4d24-b136-8ca6464badfd.png) The right Value should be Utilization=22080VA ![image](https://user-images.githubusercontent.com/94539620/157012696-ec5cfc73-effd-41f3-bc36-340e79c0a119.png)
Author
Owner

@jeremystretch commented on GitHub (Mar 7, 2022):

all

Please specify your NetBox version as indicated by the bug report template.

@jeremystretch commented on GitHub (Mar 7, 2022): > all Please specify your NetBox version as indicated by the bug report template.
Author
Owner

@svoropaev commented on GitHub (Mar 7, 2022):

All versions are affected. But just for informational reason I put the latest one 3.1.8.

@svoropaev commented on GitHub (Mar 7, 2022): > All versions are affected. But just for informational reason I put the latest one 3.1.8.
Author
Owner

@svoropaev commented on GitHub (Mar 11, 2022):

3-phase power source is assumed as 400V (not 230V) and in this case kva * 1.732 formula works.
Closing a BUG then.

@svoropaev commented on GitHub (Mar 11, 2022): 3-phase power source is assumed as 400V (not 230V) and in this case kva * 1.732 formula works. Closing a BUG then.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#6142