So, what you can do is when submitting the job on the command line, specify the –libjars option followed by the JAR file path.
The usage of the jar command is like this,
Usage: hadoop jar <jar> [mainClass] args...
If you want the commons-math3.jar to be available for all the tasks you can do any one of these
1. Copy the jar file in $HADOOP_HOME/lib dir or
2. Use the generic option -libjars.
Hope this helps!