It seem's that **w** is not used within function... 