PDA

View Full Version : Please help with basic math



cphillips82
- 12th January 2012, 11:43
Hi guys and girls....
Just wondering if you can help me with some basic maths.
I have programmed a chip for some simple phase control however I need to workout the average power given the firing angle.
searching the internet I found the equation:
average power = Vpk/4*pi*R [pi - angle+1/2*sin(2*angle)]
I HAVE NO IDEA HOW TO TYPE THIS INTO A CALCULATOR!
The angle 1/2 bit does my head in. Can somebody please translate this equation to a simpleton and do it as simple as possible.
cheers..

Acetronics2
- 12th January 2012, 12:14
Hi, That's not too difficult ... to use it with PBP

1) Pi (3.141592654 ...)
replace it by integer fraction like 22/7 or 355/113

2) here, angles are expressed in radians ... just change to BINARY radians PBP can deal with
2*pi rads = 360° = 255 binary radians ...

and keep a sharp eye on overflows ( depending on the processor used : 16F - 16 Bits unsigned, 18F with longs - 31 signed bits )

That's all !!!

looks it applies to a resistive load ( lamp, heather ...) but not to inductive loads ... like motors.

Alain

cphillips82
- 13th January 2012, 04:06
Hi, That's not too difficult ... to use it with PBP

1) Pi (3.141592654 ...)
replace it by integer fraction like 22/7 or 355/113

2) here, angles are expressed in radians ... just change to BINARY radians PBP can deal with
2*pi rads = 360° = 255 binary radians ...

and keep a sharp eye on overflows ( depending on the processor used : 16F - 16 Bits unsigned, 18F with longs - 31 signed bits )

That's all !!!

looks it applies to a resistive load ( lamp, heather ...) but not to inductive loads ... like motors.

Alain

Thanks for your reply Alain but before I can try to implement the equation into the programme I need to know how to calculate it with a calculator.

6221
The answer is meant to be 480W but I don't get close to it. The bit in brackets comes out with a negative number??
Should have stayed at school I guess..

Kamikaze47
- 15th January 2012, 07:11
The angle needs to be in radians. If you multiply the angle in degrees by Pi/180 you will get the angle in radians.

When you do so, it comes out to 480. (http://www.wolframalpha.com/input/?i=325^2%2F(4*Pi*50)*(Pi-45*(Pi%2F180)%2B(1%2F2)*sin(2*45*(Pi%2F180))))