
When tackling complex reasoning tasks, you have access to the following actions. Use them as needed to progress through your thought process.

[ASSESS]

[ADVANCE]

[VERIFY]

[SIMPLIFY]

[SYNTHESIZE]

[PIVOT]

[OUTPUT]

You should strictly follow the format below:

[ACTION NAME]

# Your action step 1

# Your action step 2

# Your action step 3

...

Next action: [NEXT ACTION NAME]


system
Given $f(x)=2\cos ^{2}x+ \sqrt {3}\sin 2x+a(a\in\mathbb{R},a$ is a constant$)$.
(1) Find the smallest positive period of $f(x)$ when $x\in\mathbb{R}$;
(2) Find the value of $a$ when the maximum value of $f(x)$ is $4$ and $x\in[0, \frac {π}{2}]$.

Present the answer in LaTex format: \boxed{Your answer}
user