(1)f(x)=asinx+cosx的最大值是2
∴√(a^2+1^2)=2
∴a=√3
∴f(x)=√3sinx+cosx
=2[(√3sinx)/2+(cosx)/2]
=2sin(x+30°)
∵单调递增
∴x+30°∈[2kπ-π/2,2kπ+π/2]
∴x∈[2kπ-2π/3,2kπ+π/3]
(2)x∈[0,π]
∴x+30∈[π/6,7π/6]
∴sin(x+30°)∈[-1/2,1]
∴f(x)∈[-1,2]
应该着样
(1)f(x)=asinx+cosx的最大值是2
∴√(a^2+1^2)=2
∴a=√3
∴f(x)=√3sinx+cosx
=2[(√3sinx)/2+(cosx)/2]
=2sin(x+30°)
∵单调递增
∴x+30°∈[2kπ-π/2,2kπ+π/2]
∴x∈[2kπ-2π/3,2kπ+π/3]
(2)x∈[0,π]
∴x+30∈[π/6,7π/6]
∴sin(x+30°)∈[-1/2,1]
∴f(x)∈[-1,2]
应该着样