
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 the function $f(x) = \sin 2x \cos \varphi + \cos 2x \sin \varphi$ ($x \in \mathbb{R}, 0 < \varphi < \pi$), and $f\left( \frac{\pi}{4} \right) = \frac{\sqrt{3}}{2}$.

(1) Find the expression for $f(x)$;  
(2) If $f\left( \frac{a}{2} - \frac{\pi}{3} \right) = \frac{5}{13}$, where $a \in \left( \frac{\pi}{2}, \pi \right)$, find the value of $\sin a$.

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