Short answer
monthly_payment = PMT(rate/12, amortization_in_years*12, principal)
weekly_payment = monthly_payment * 12 / 52
Long answer
Variable rate mortgages in Canada are often compounded monthly, but sometimes semi-annually according to this post on RedFlagDeals from 2009:
As per law the fixed rates mortgages in Canada are compounded semi
annually while in variable rate mortgages banks can chose the way they
compound the interest. Most banks compound the interest for their
variable rate mortgages as monthly while some banks such as National
Bank, ING Direct and Scotiabank on one of its variable mortgage
compound the interest semi annually.
For monthly payments compounded monthly:
monthly_payment = PMT(rate/12, amortization_in_years*12, principal)
= PMT(0.03/12, 25*12, 500000)
= -2371.06
This result matches the mortgage calculators at RBC, BMO and TD.
For monthly payments compounded semi-annually:
monthly_rate = (1+(rate/2))^(2/12)-1
= (1+(0.03/2))^(2/12)-1
= 0.002484516
monthly_payment = PMT(monthly_rate, amortization_in_years*12, principal)
= PMT(0.002484516, 25*12, 500000)
= -2366.23
This result matches the mortgage calculator at National Bank.
For weekly payments:
weekly_payment = monthly_payment * 12 / 52
= -2371.05 * 12 / 52
= -547.17
Each bank seems to calculate weekly payments slightly differently: RBC $547.17, BMO $544.77 and TD $545.02. As suggested by @brian, this formula gives us a rough answer by just dividing the total year's payments into weeks.