Icons were added

This commit is contained in:
Evgeny Redikultsev
2023-08-12 14:53:38 +05:00
parent ce97586d2b
commit 80302525b3
103 changed files with 1133 additions and 449 deletions

View File

@@ -0,0 +1,53 @@
using StructureHelperCommon.Infrastructures.Exceptions;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace StructureHelperLogics.NdmCalculations.Cracking
{
public class CrackWidthLogicSP63 : ICrackWidthLogic
{
public double RebarStrain { get; set; }
public double ConcreteStrain { get; set; }
public double Length { get; set; }
public double TermFactor { get; set; }
public double BondFactor { get; set; }
public double StressStateFactor { get; set; }
public double PsiSFactor { get; set; }
public double GetCrackWidth()
{
CheckOptions();
//check if strain of concrete greater than strain of rebar
if (ConcreteStrain > RebarStrain) { return 0d; }
double width = (RebarStrain - ConcreteStrain) * Length;
width *= TermFactor * BondFactor * StressStateFactor * PsiSFactor;
return width;
}
private void CheckOptions()
{
if (Length <=0d)
{
throw new StructureHelperException(ErrorStrings.DataIsInCorrect + $": length between cracks L={Length} must be greate than zero");
}
if (TermFactor <= 0d)
{
throw new StructureHelperException(ErrorStrings.DataIsInCorrect + $": Term factor {TermFactor} must be greate than zero");
}
if (BondFactor <= 0d)
{
throw new StructureHelperException(ErrorStrings.DataIsInCorrect + $": Bond factor {BondFactor} must be greate than zero");
}
if (StressStateFactor <= 0d)
{
throw new StructureHelperException(ErrorStrings.DataIsInCorrect + $": Bond factor {StressStateFactor} must be greate than zero");
}
if (PsiSFactor <= 0d)
{
throw new StructureHelperException(ErrorStrings.DataIsInCorrect + $": PsiS factor {PsiSFactor} must be greate than zero");
}
}
}
}