public double GetGeometryFactor(LoadToGrainDirection LoadToGrainDirection, FastenerEdgeBearingType FastenerEdgeBearingType, double L_end,
                                        double L_spacing,
                                        double l_m, double l_s, bool IsLoadedEdge, bool IsSoftwood, bool IsLoadedAtAngle)
        {
            double C_Delta = 0;

            this.l_m          = l_m;
            this.l_s          = l_s;
            this.IsLoadedEdge = IsLoadedEdge;

            throw new NotImplementedException();
            if (this.D <= 0.25)
            {
                C_Delta = 1.0;
            }
            else
            {
                //End distance C_Delta
                double C_DeltaEnd     = GetEndDistanceC_Delta(LoadToGrainDirection, FastenerEdgeBearingType, L_end, IsSoftwood, IsLoadedAtAngle);
                double C_DeltaSpacing = GetSpacingC_Delta(LoadToGrainDirection, L_spacing);
                //Add edge disstance here
            }

            return(C_Delta);
        }
        private double GetEndDistanceC_Delta(LoadToGrainDirection LoadToGrainDirection, FastenerEdgeBearingType FastenerEdgeBearingType,
                                             double L_end, bool IsSoftwood, bool IsLoadedAtAngle)
        {
            if (IsLoadedAtAngle == true)
            {
                throw new Exception("Loading at angle to the fastener is not supported.");
            }
            double L_endC_delta05 = GetMinimumEndDistance(LoadToGrainDirection, FastenerEdgeBearingType);

            if (L_end < L_endC_delta05)
            {
                throw new Exception("End distance is smaller than minimum permitted. Revise design.");
            }
            double L_endC_delta1 = GetMinimumEndDistanceForMaximumStrength(LoadToGrainDirection, FastenerEdgeBearingType, IsSoftwood);
            double C_Delta       = L_end / (L_endC_delta1);

            return(C_Delta);
        }
        //Table 12.5.1A End Distance Requirements
        public double GetMinimumEndDistanceForMaximumStrength(LoadToGrainDirection LoadToGrainDirection, FastenerEdgeBearingType FastenerEdgeBearingType, bool IsSoftwood)
        {
            switch (LoadToGrainDirection)
            {
            case LoadToGrainDirection.ParallelToGrain:
                if (FastenerEdgeBearingType == Kodestruct.Wood.NDS.Entities.FastenerEdgeBearingType.CompressionBearingAwayFromEdge)
                {
                    return(4.0 * D);
                }
                else
                {
                    if (IsSoftwood)
                    {
                        return(7.0 * D);
                    }
                    else
                    {
                        return(5.0 * D);
                    }
                }
                break;

            case LoadToGrainDirection.PerpendicularToGrain:
                return(4.0 * D);

                break;

            default:
                throw new Exception("LoadToGrainDirection not recognized");
                break;
            }
        }