Try using Java(code) to implement the behavior of a mathematical equation like solving a sine or cosine equation with a set of array or vector input variables.
Then add code to render the results on a XYZ chart (trigonometry & geometry maths) which can be done in a browser using CSS.