Here is the code
for (int g=1;g < V+1 ;g++) {
System.out.println("For LOOP"+g);
if (point1 != g){
dis =...
Type: Posts; User: mingming8888
Here is the code
for (int g=1;g < V+1 ;g++) {
System.out.println("For LOOP"+g);
if (point1 != g){
dis =...
I have delete all related static from the method, and now i got another error, it is
"Exception in thread "AWT-EventQueue-0" java.lang.StackOverflowError
at...
Hi, i am using package, and i want to call a method in the other java file called triangle, but it can't. i tried to pass this
Triangle tri = new Triangle();
tri. create();
but it said...
u mean this??
at triangle_projection.P.p(Prim.java:69) - for(int i=0;i<=tedges.length;i++)
at triangle_projection.P.buildTable(Prim.java:55) - p();
at triangle_projection.P.main(Prim.java:178) -...
i have tried to run it, and i got the result below
1
2
50
1
3
60
1
4
70
This is the code
import java.io.*;
public class P {
public static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
public static int [][] Graph;
public static int...
Hi,
when i run my program, it shows this
"Exception in thread "main" java.lang.NullPointerException"
but my array doesn't not contain any null value, how can i check if the array is null or not,...
Because my x and y is a double value, is it i can passed a double value into it? i want to be more accurate, so i want it to be a double value for x and y.
The file contains:
1 2 50
1 3 60
1 4 70
2 3 80
2 4 40
3 4 60
private void drawNode(double x, double y, double no, Graphics g) {
g.fillOval(x, y, 17, 17); // draw an oval which is filled with the current color
g.setColor(blue); // set current color to...
import java.io.*;
public class Prim {
public static BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
....
public static tempEdge [] tedges;
....
...
package triangle_projection;
import java.io.*;
import java.awt.*;
public class Prim extends JComponent {
public static int [][] Graph;
public static int [][] Tree;
public static int []...
i don't really understand unit vector, so i don't know how to calculate this, can anyone please help me to solve it?
A(10,0), B(5,8.7) find the unit vector v1 n v2, also find a unit vector w,...
Thank you for your explanation
yea, they have the same distance, so Prim's algorithm will choose which path first? If we start the tree from A, so the next one is B, C or D?
For prim's algorithm, if a vertice have the same weight to other vertices, so which one will it be choosen to put in the tree?
For example
A to B is 3
A to C is 3
A to D is 3
B to C is 3
B to...
Hi
Does anyone have the code of Delaunay triangulation?
Thank you
yes, x and y
after point 1 is projected, the right distance is the distance between point 1 and point 2 is the distance in the original space.
For example
Point 1 is (0,0)
Point 2 is...
Yea, the 3rd point is equidistant from 1 and 2, so the 2 solutions are a positive and negative y, is it? then i will take the positive one. But how can i do this?
The algorithm is
Pick a point and put it at the origin (0,0)
Put the second point to the right distance away from the 1st point (0, distance(Point 1, Point 2))
The 3rd point is the intersect of...
i have added j3dtree.jar
Here is the hand1.obj
Hi
i try to run the program below, but i don't know why i can't run it.
There is something wrong with the import com.sun.j3d, how can i fix it?
Thank you
import java.applet.Applet;
import...
yea, i dont know how to start doing this program....
Hi
i am working on information visualization, which use triangle projection to do it, that get n points from a higher dimensional space to a 2 dimensional space. i need to project points from an...