
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 a non-empty set $A=\{x|a \lt x\leqslant a^{2}-2\}$, $B=(1,5)$.  
$(1)$ When $a=3$, find $A\cup B$;  
$(2)$ If $A\cup B=B$, find the range of real number $a$.

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