How to plot the graph of the equation like this using java program

A cos (wt-bz) where w and b are constants. There will be two axes t and z. t will be plotted in the y direction and z in the x direction. Z points will be 0.1,0.2,0.3...... and in first case when t=0, graph will show the value of the equation (given above) , then gradually when t=1, t=2, etc....

Please help me to solve the problem !!