// Path: src/net/sourceforge/arbaro/tree/Tree.java
// public interface Tree {
// 
// 	/**
// 	 * used with the TreeTraversal interface
// 	 *
// 	 * @param traversal
// 	 * @return when false stop travers the tree
// 	 */
// 	abstract boolean traverseTree(TreeTraversal traversal);
// 
// 	/**
// 	 *
// 	 * @return the number of all stems of all levels of the tree
// 	 */
// 	public abstract long getStemCount();
// 
// 	/**
// 	 *
// 	 * @return the number of leaves of the tree
// 	 */
// 	public abstract long getLeafCount();
// 
// 	/**
// 	 *
// 	 * @return a vector with the highest coordinates of the tree.
// 	 * (Considering all stems of all levels)
// 	 */
// 	public abstract Vector getMaxPoint();
// 
// 	/**
// 	 *
// 	 * @return a vector with the lowest coordinates of the tree.
// 	 * (Considering all stems of all levels)
// 	 */
// 	public abstract Vector getMinPoint();
// 
// 	/**
// 	 *
// 	 * @return the seed of the tree. It is used for randomnization.
// 	 */
// 	public int getSeed();
// 
// 	/**
// 	 *
// 	 * @return the height of the tree (highest z-coordinate)
// 	 */
// 	public double getHeight();
// 
// 	/**
// 	 *
// 	 * @return the widht of the tree (highest value of sqrt(x*x+y*y))
// 	 */
// 	public double getWidth();
// 
// 	/**
// 	 * Writes the trees parameters to a stream
// 	 * @param w
// 	 */
// 	public void paramsToXML(PrintWriter w);
// 
// 	/**
// 	 *
// 	 * @return the tree species name
// 	 */
// 	public String getSpecies();
// 
// 	/**
// 	 *
// 	 * @return the tree scale
// 	 */
// 	public double getScale();
// 
// 	/**
// 	 *
// 	 * @return the tree stem levels
// 	 */
// 	public int getLevels();
// 
// 	/**
// 	 *
// 	 * @return the leaf shape name
// 	 */
// 	public String getLeafShape();
// 
// 	/**
// 	 *
// 	 * @return the leaf width
// 	 */
// 	public double getLeafWidth();
// 
// 	/**
// 	 *
// 	 * @return the leaf length
// 	 */
// 	public double getLeafLength();
// 
// 	/**
// 	 *
// 	 * @return the virtual leaf stem length, i.e. the distance of
// 	 * the leaf from the stem center line
// 	 */
// 	public double getLeafStemLength();
// 
// 	/**
// 	 * Use this for verbose output when generating a mesh or
// 	 * exporting a tree
// 	 *
// 	 * @param level
// 	 * @return an information string with the number of section
// 	 * points for this stem level and if smoothing should be used
// 	 */
// 	public String getVertexInfo(int level);
// 
// }
// 
// Path: src/net/sourceforge/arbaro/tree/TreeGeneratorFactory.java
// public class TreeGeneratorFactory {
// 	static public TreeGenerator createTreeGenerator() {
// 		return new TreeGeneratorImpl();
// 	}
// 
// 	static public TreeGenerator createTreeGenerator(Params params) {
// 		return new TreeGeneratorImpl(params);
// 	}
// 
// 	static public TreeGenerator createShieldedTreeGenerator() {
// 		return new ShieldedTreeGenerator(new TreeGeneratorImpl());
// 	}
// 
// 	static public TreeGenerator createShieldedTreeGenerator(Params params) {
// 		return new ShieldedTreeGenerator(new TreeGeneratorImpl(params));
// 	}
// 
// 
// }	


import junit.framework.TestCase;
import net.sourceforge.arbaro.tree.Tree;
import net.sourceforge.arbaro.tree.TreeGenerator;
import net.sourceforge.arbaro.tree.TreeGeneratorFactory;
import net.sourceforge.arbaro.params.*;
import net.sourceforge.arbaro.feedback.Progress;
import java.util.*;
import java.io.*;
package net.sourceforge.arbaro.tree.impl;



//import net.sourceforge.arbaro.params.impl.AbstractParam;
//import net.sourceforge.arbaro.params.impl.FloatParam;
//import net.sourceforge.arbaro.params.impl.IntParam;


public class treeTest extends TestCase {
	static final double prec=0.0000000001;
	
	static final String sassafrasCfg = 
		"species=sassafras\n"+
		"Shape=2\n"+
		"Levels=4\n"+
		"Scale=23\n"+
		"ScaleV=7\n"+
//		"ZScale=1\n"+
//		"ZScaleV=0\n"+
		"BaseSize=0.2\n"+
		"Ratio=0.02\n"+
		"RatioPower=1.3\n"+
		"Lobes=3\n"+
		"LobeDepth=0.05\n"+
		"Flare=0\n"+
		"Leaves=15\n"+
		"LeafShape=0\n"+
		"LeafScale=0.25\n"+
		"LeafScaleX=0.7\n"+
		"AttractionUp=0\n"+
		"LeafQuality=1\n"+
		"PruneRatio=0\n"+
		"0Scale=1\n"+
// Path: src/net/sourceforge/arbaro/tree/Tree.java
// public interface Tree {
// 
// 	/**
// 	 * used with the TreeTraversal interface
// 	 *
// 	 * @param traversal
// 	 * @return when false stop travers the tree
// 	 */
// 	abstract boolean traverseTree(TreeTraversal traversal);
// 
// 	/**
// 	 *
// 	 * @return the number of all stems of all levels of the tree
// 	 */
// 	public abstract long getStemCount();
// 
// 	/**
// 	 *
// 	 * @return the number of leaves of the tree
// 	 */
// 	public abstract long getLeafCount();
// 
// 	/**
// 	 *
// 	 * @return a vector with the highest coordinates of the tree.
// 	 * (Considering all stems of all levels)
// 	 */
// 	public abstract Vector getMaxPoint();
// 
// 	/**
// 	 *
// 	 * @return a vector with the lowest coordinates of the tree.
// 	 * (Considering all stems of all levels)
// 	 */
// 	public abstract Vector getMinPoint();
// 
// 	/**
// 	 *
// 	 * @return the seed of the tree. It is used for randomnization.
// 	 */
// 	public int getSeed();
// 
// 	/**
// 	 *
// 	 * @return the height of the tree (highest z-coordinate)
// 	 */
// 	public double getHeight();
// 
// 	/**
// 	 *
// 	 * @return the widht of the tree (highest value of sqrt(x*x+y*y))
// 	 */
// 	public double getWidth();
// 
// 	/**
// 	 * Writes the trees parameters to a stream
// 	 * @param w
// 	 */
// 	public void paramsToXML(PrintWriter w);
// 
// 	/**
// 	 *
// 	 * @return the tree species name
// 	 */
// 	public String getSpecies();
// 
// 	/**
// 	 *
// 	 * @return the tree scale
// 	 */
// 	public double getScale();
// 
// 	/**
// 	 *
// 	 * @return the tree stem levels
// 	 */
// 	public int getLevels();
// 
// 	/**
// 	 *
// 	 * @return the leaf shape name
// 	 */
// 	public String getLeafShape();
// 
// 	/**
// 	 *
// 	 * @return the leaf width
// 	 */
// 	public double getLeafWidth();
// 
// 	/**
// 	 *
// 	 * @return the leaf length
// 	 */
// 	public double getLeafLength();
// 
// 	/**
// 	 *
// 	 * @return the virtual leaf stem length, i.e. the distance of
// 	 * the leaf from the stem center line
// 	 */
// 	public double getLeafStemLength();
// 
// 	/**
// 	 * Use this for verbose output when generating a mesh or
// 	 * exporting a tree
// 	 *
// 	 * @param level
// 	 * @return an information string with the number of section
// 	 * points for this stem level and if smoothing should be used
// 	 */
// 	public String getVertexInfo(int level);
// 
// }
// 
// Path: src/net/sourceforge/arbaro/tree/TreeGeneratorFactory.java
// public class TreeGeneratorFactory {
// 	static public TreeGenerator createTreeGenerator() {
// 		return new TreeGeneratorImpl();
// 	}
// 
// 	static public TreeGenerator createTreeGenerator(Params params) {
// 		return new TreeGeneratorImpl(params);
// 	}
// 
// 	static public TreeGenerator createShieldedTreeGenerator() {
// 		return new ShieldedTreeGenerator(new TreeGeneratorImpl());
// 	}
// 
// 	static public TreeGenerator createShieldedTreeGenerator(Params params) {
// 		return new ShieldedTreeGenerator(new TreeGeneratorImpl(params));
// 	}
// 
// 
// }	


// Path: test/net/sourceforge/arbaro/tree/impl/treeTest.java
import junit.framework.TestCase;
import net.sourceforge.arbaro.tree.Tree;
import net.sourceforge.arbaro.tree.TreeGenerator;
import net.sourceforge.arbaro.tree.TreeGeneratorFactory;
import net.sourceforge.arbaro.params.*;
import net.sourceforge.arbaro.feedback.Progress;
import java.util.*;
import java.io.*;

package net.sourceforge.arbaro.tree.impl;



//import net.sourceforge.arbaro.params.impl.AbstractParam;
//import net.sourceforge.arbaro.params.impl.FloatParam;
//import net.sourceforge.arbaro.params.impl.IntParam;


public class treeTest extends TestCase {
	static final double prec=0.0000000001;
	
	static final String sassafrasCfg = 
		"species=sassafras\n"+
		"Shape=2\n"+
		"Levels=4\n"+
		"Scale=23\n"+
		"ScaleV=7\n"+
//		"ZScale=1\n"+
//		"ZScaleV=0\n"+
		"BaseSize=0.2\n"+
		"Ratio=0.02\n"+
		"RatioPower=1.3\n"+
		"Lobes=3\n"+
		"LobeDepth=0.05\n"+
		"Flare=0\n"+
		"Leaves=15\n"+
		"LeafShape=0\n"+
		"LeafScale=0.25\n"+
		"LeafScaleX=0.7\n"+
		"AttractionUp=0\n"+
		"LeafQuality=1\n"+
		"PruneRatio=0\n"+
		"0Scale=1\n"+
		"0ScaleV=0\n"+