Here you can find the source of sin(float n)
public static float sin(float n)
//package com.java2s; //License from project: Open Source License public class Main { private static final float[] sin = new float[65536]; public static float sin(float n) { return sin[(int) (n * 10430.378F) & 0xffff]; }//from ww w .j a va 2s . com }