Java Array Cross Product cross(int x1, int y1, int x2, int y2)

Here you can find the source of cross(int x1, int y1, int x2, int y2)

Description

cross

License

Open Source License

Declaration

public static double cross(int x1, int y1, int x2, int y2) 

Method Source Code

//package com.java2s;
/*/*from  w  w  w . ja v a  2  s. com*/
 *                      ..::jDrawingLib::..
 *
 * Copyright (C) Federico Vera 2012 - 2014 <dktcoding [at] gmail>
 *
 * This program is free software: you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the
 * Free Software Foundation, either version 3 of the License, or any later
 * version.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along
 * with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

public class Main {
    public static double cross(int x1, int y1, int x2, int y2) {
        return (x1 * y2) - (y1 * x2);
    }
}

Related

  1. cross(double[] vec1, double[] vec2, double[] outvec)
  2. cross(final double[] a, final double[] b, final double[] c)
  3. cross(final double[] left, final double[] right)
  4. cross(float[] v1, float[] v2, float[] out)
  5. cross(float[] vec1, float[] vec2)
  6. cross2D(final float[] v1, final float[] v2)
  7. cross2D(int[] v, int[] u)
  8. cross3(double x1, double y1, double z1, double x2, double y2, double z2)
  9. cross33(float u[], float v[])