XXX: This is just a prototype
@param x real part
@param y imaginary part
@return the real and imaginary part of the transform
356349
public static List<ListNumber> dft(ListNumber x, ListNumber y) {
        if (x.size() != y.size()) {
            throw new IllegalArgumentException("Real and imaginary part must be of the same length");
        }
        
        double cosarg,sinarg;
        double[] resX = new double[x.size()];
        double[] resY = new double[x.size()];
        int direction = 1; // -1 would be inverse
        double size = x.size();

        for (int i = 0; i < x.size(); i++) {
            double arg = - direction * 2.0 * Math.PI * (double) i / size;
            for (int k = 0; k < x.size(); k++) {
                cosarg = Math.cos(k * arg);
                sinarg = Math.sin(k * arg);
                resX[i] += (x.getDouble(k) * cosarg - y.getDouble(k) * sinarg);
                resY[i] += (x.getDouble(k) * sinarg + y.getDouble(k) * cosarg);
            }
        }

        if (direction == 1) {
            for (int i = 0; i < x.size(); i++) {
                resX[i] = resX[i] / size;
                resY[i] = resY[i] / size;
            }
            return Arrays.<ListNumber>asList(new ArrayDouble(resX), new ArrayDouble(resY));
        } else {
            return Arrays.<ListNumber>asList(new ArrayDouble(resY), new ArrayDouble(resX));
        }
    }
481634
private SimpleMatrix translateToOrigin( int x0 , int y0 ) {

		SimpleMatrix T = SimpleMatrix.identity(3);

		T.set(0, 2, -x0);
		T.set(1, 2, -y0);

		return T;
	}
1008632
public final Shape<?> findShapeAtPoint(final int x, final int y)
    {
        if (isVisible())
        {
            final NFastArrayList<Layer> layers = getChildNodes();

            if (null != layers)
            {
                final int size = layers.size();

                for (int i = size - 1; i >= 0; i--)
                {
                    final Layer layer = layers.get(i);

                    if (null != layer)
                    {
                        final Shape<?> shape = layer.findShapeAtPoint(x, y);

                        if (null != shape)
                        {
                            return shape;
                        }
                    }
                }
            }
        }
        return null;
    }
1029749
@Override
    public C setScale(final double x, final double y)
    {
        getAttributes().setScale(x, y);

        return cast();
    }
778092
public static double atan2(double y, double x) {
        if (x != x || y != y) {
            return Double.NaN;
        }

        if (y == 0) {
            final double result = x * y;
            final double invx = 1d / x;
            final double invy = 1d / y;

            if (invx == 0) { // X is infinite
                if (x > 0) {
                    return y; // return +/- 0.0
                } else {
                    return copySign(Math.PI, y);
                }
            }

            if (x < 0 || invx < 0) {
                if (y < 0 || invy < 0) {
                    return -Math.PI;
                } else {
                    return Math.PI;
                }
            } else {
                return result;
            }
        }

        // y cannot now be zero

        if (y == Double.POSITIVE_INFINITY) {
            if (x == Double.POSITIVE_INFINITY) {
                return Math.PI * F_1_4;
            }

            if (x == Double.NEGATIVE_INFINITY) {
                return Math.PI * F_3_4;
            }

            return Math.PI * F_1_2;
        }

        if (y == Double.NEGATIVE_INFINITY) {
            if (x == Double.POSITIVE_INFINITY) {
                return -Math.PI * F_1_4;
            }

            if (x == Double.NEGATIVE_INFINITY) {
                return -Math.PI * F_3_4;
            }

            return -Math.PI * F_1_2;
        }

        if (x == Double.POSITIVE_INFINITY) {
            if (y > 0 || 1 / y > 0) {
                return 0d;
            }

            if (y < 0 || 1 / y < 0) {
                return -0d;
            }
        }

        if (x == Double.NEGATIVE_INFINITY)
        {
            if (y > 0.0 || 1 / y > 0.0) {
                return Math.PI;
            }

            if (y < 0 || 1 / y < 0) {
                return -Math.PI;
            }
        }

        // Neither y nor x can be infinite or NAN here

        if (x == 0) {
            if (y > 0 || 1 / y > 0) {
                return Math.PI * F_1_2;
            }

            if (y < 0 || 1 / y < 0) {
                return -Math.PI * F_1_2;
            }
        }

        // Compute ratio r = y/x
        final double r = y / x;
        if (Double.isInfinite(r)) { // bypass calculations that can create NaN
            return atan(r, 0, x < 0);
        }

        double ra = doubleHighPart(r);
        double rb = r - ra;

        // Split x
        final double xa = doubleHighPart(x);
        final double xb = x - xa;

        rb += (y - ra * xa - ra * xb - rb * xa - rb * xb) / x;

        final double temp = ra + rb;
        rb = -(temp - ra - rb);
        ra = temp;

        if (ra == 0) { // Fix up the sign so atan works correctly
            ra = copySign(0d, y);
        }

        // Call atan
        final double result = atan(ra, rb, x < 0);

        return result;
    }
1090689
public static int crossShape (IShape s, float x, float y) {
        if (!s.bounds().contains(x, y)) {
            return 0;
        }
        return crossPath(s.pathIterator(null), x, y);
    }
68797
public Quaternion fromAnglesXY (float x, float y) {
        float hx = x * 0.5f, hy = y * 0.5f;
        float sx = FloatMath.sin(hx), cx = FloatMath.cos(hx);
        float sy = FloatMath.sin(hy), cy = FloatMath.cos(hy);
        return set(cy*sx, sy*cx, -sy*sx, cy*cx);
    }
1126529
function (x, y) {
        var coord = this.transformCoordToLocal(x, y);
        var rect = this.getBoundingRect();
        return rect.contain(coord[0], coord[1]);
    }
272044
@Override 
    public double fromReal(double x) {
        long sign = POSITIVE;
        if (x < 0) {
            sign = NEGATIVE;
            x = -x;  
        }
        return compact(sign, FastMath.log(x));
    }
1303968
public void transform(Tuple3D<?> t) {
		double x, y, z;
		x = this.m00 * t.getX() + this.m01 * t.getY() + this.m02 * t.getZ() + this.m03;
		y = this.m10 * t.getX() + this.m11 * t.getY() + this.m12 * t.getZ() + this.m13;
		z = this.m20 * t.getX() + this.m21 * t.getY() + this.m22 * t.getZ() + this.m23;
		t.set(x, y, z);
	}
114766
@Override
    public T setScale(final double x, final double y)
    {
        getAttributes().setScale(x, y);

        return cast();
    }
498268
public Translation to(float x, float y, float z)
	{
		toX = x;
		toY = y;
		toZ = z;
		return this;
	}
470946
public static IntegerBinding addExact(final ObservableIntegerValue x, final ObservableIntegerValue y) {
        return createIntegerBinding(() -> Math.addExact(x.get(), y.get()), x, y);
    }
1189890
@Pure
	public static String makeInternalId(float x, float y) {
		final StringBuilder buf = new StringBuilder("point"); //$NON-NLS-1$
		buf.append(x);
		buf.append(';');
		buf.append(y);
		return Encryption.md5(buf.toString());
	}
903200
public Image getSubImage(int x, int y) {
		init();
		
		if ((x < 0) || (x >= subImages.length)) {
			throw new RuntimeException("SubImage out of sheet bounds: "+x+","+y);
		}
		if ((y < 0) || (y >= subImages[0].length)) {
			throw new RuntimeException("SubImage out of sheet bounds: "+x+","+y);
		}
		
		return subImages[x][y];
	}
1073303
function(x,y,z){
        return x>=this.minX&&x<=this.maxX&&y>=this.minY&&y<=this.maxY&&z>=this.minZ&&z<=this.maxZ;
    }
744753
function getComponentAt(x, y) {
            if (this.$translateX !== 0 || this.$translateY !== 0 || this.$rotateValue !== 0 || this.$scaleX !== 1 || this.$scaleY !== 1) {
                var xy = this.project(x, y);
                return this.$super(xy[0], xy[1]);
            } else {
                return this.$super(x, y);
            }
        }