public static double SunShineSim(TreeModel treeModel, PhotosyntheticModels type)
    {
        double biomass = 0.0;

        switch (type)
        {
        case PhotosyntheticModels.LightResponse:
            Octree octree = Octree.Build(treeModel);
            biomass =
                octree == null?         //无模型,说明未出苗
                MaizeParams.SEED_BIOMASS : DailySunShineSimluation(treeModel, DateTime.Now, 119, 26, octree, 0.1f, 100, 100);
            if (octree != null)
            {
                octree.Clear();
            }
            break;

        default:
            GameObject go = treeModel.TreeModelInstance;

            if (go != null)
            {
                Mesh.AddBoxColliderInParent(go);
            }

            biomass =
                treeModel.GetLeafIndexes().Count != 0 ?         //无叶片,说明未出苗
                BeerRule.BiomassCal(treeModel) / FunctionSim.ComputeDaysInGC(treeModel) : MaizeParams.SEED_BIOMASS;
            break;
        }

        if (biomass != MaizeParams.SEED_BIOMASS)
        {
            biomass *= EnvironmentEffect.TemperatureStressFactor(treeModel) * EnvironmentEffect.WaterStressFactor(treeModel) * EnvironmentEffect.SunshineStress(treeModel);
        }

        return(biomass);
    }
    /// <summary>
    /// 各叶片分配光合产物
    /// </summary>
    /// <param name="biomass">分配到叶片的生物量</param>
    private static void LeafPhotosynthateAllocation(TreeModel treeModel, double biomass)
    {
        List <LeafIndex> indexes = treeModel.GetLeafIndexes();                          //获取该类型器官的索引

        OrganPhotosynthateAllocation <LeafIndex>(MaizeParams.LEAF_S, biomass, indexes); //分配生物量
    }