f(x)=向量a.向量b
=√3sinxcosx-(1/2)cos2x.
=(√3/2)sin2x-(1/2)cos2x.
∴f(x)=sin(2x-π/6).
(1) 函数f(x)的最小正周期 T=2π/2=π;
(2)∵0≤x≤π/2,∴ -π/6≤2x-π/6≤5π/6.
∵f(x)=sin(2x-π/6)在区间[0,π/3]上单调递增,在区间[π/3,π/2]上单调递减,∴当x=π/3时,f(x)取得最大值1;又∵f(0)=sin(-π/6)=-(1/2),f(π/2)=sin(π-π/6)=sinπ/6=1/2,∴f(0)<f(π/2)√
∴当x=0时,f(x)=sin(2x-π/6)取得最小值(-1/2).
∴f(x)=sin(2x-π/6)在[0,π/2]上的最大值f(x)max=1;最小值f(x)min=-1/2.