def runChecking(self,limitStateData,matDiagType,threeDim= True,outputCfg=oc.verifOutVars()): '''Creates the phantom model and runs the verification on it. :param limitStateData: object that contains the name of the file containing the internal forces obtained for each element for the combinations analyzed and the controller to use for the checking. :param matDiagType: type of the material diagram (d: design, k: characteristic). :param threeDim: true if it's 3D (Fx,Fy,Fz,Mx,My,Mz) false if it's 2D (Fx,Fy,Mz). :param outputCfg: instance of class 'verifOutVars' which defines the variables that control the output of the checking (set of elements to be analyzed, append or not the results to a file, generation or not of lists, ...) ''' feProblem= xc.FEProblem() preprocessor= feProblem.getPreprocessor if 'straight' in str(limitStateData.controller).lower(): for s in self.sectionDefinition.sections: s.concrType.initTensStiff='Y' self.sectionDefinition.createRCsections(preprocessor,matDiagType) #creates #for each element in the container the fiber sections #(RCsimpleSections) associated with it. if(threeDim): self.sectionDefinition.calcInteractionDiagrams(preprocessor,matDiagType) else: self.sectionDefinition.calcInteractionDiagrams(preprocessor,matDiagType,'NMy') limitStateData.controller.analysis= limitStateData.controller.analysisToPerform(feProblem) phantomModel= phm.PhantomModel(preprocessor,self) result= phantomModel.runChecking(limitStateData,outputCfg) return (feProblem, result)
def check(self,reinfConcreteSections,outputCfg=oc.verifOutVars()): '''Checking of fatigue under fatigue combinations loads in ultimate limit states (see self.dumpCombinations). :param reinfConcreteSections: Reinforced concrete sections on each element. :param outputCfg: instance of class 'verifOutVars' which defines the variables that control the output of the checking (set of elements to be analyzed, append or not the results to a file, generation or not of lists, ...) ''' return reinfConcreteSections.internalForcesVerification3D(self, "d",outputCfg)
def check(self,reinfConcreteSections,outputCfg=oc.verifOutVars()): '''Checking of crack width under quasi-permanent loads in serviceability limit states (see self.dumpCombinations). :param reinfConcreteSections: Reinforced concrete sections on each element. :param outputCfg: instance of class verifOutVars which defines the variables that control the output of the checking (set of elements to be analyzed, append or not the results to file, generation or not of lists, ...) ''' return reinfConcreteSections.internalForcesVerification3D(self,"k",outputCfg)
beamRCsect.creaTwoSections() sections.append(beamRCsect) # Spatial distribution of reinforced concrete # sections (assign RC sections to elements). reinfConcreteSectionDistribution.assign(elemSet=totalSet.getElements, setRCSects=beamRCsect) #Checking shear. lsd.shearResistance.controller = EHE_limit_state_checking.ShearController( limitStateLabel=lsd.shearResistance.label) lsd.shearResistance.controller.analysisToPerform = predefined_solutions.simple_newton_raphson lsd.LimitStateData.check_results_directory = '/tmp/' lsd.normalStressesResistance.outputDataBaseFileName = 'resVerif' outCfg = oc.verifOutVars(listFile='N', calcMeanCF='Y') (FEcheckedModel, meanFCs) = reinfConcreteSectionDistribution.runChecking(lsd.shearResistance, matDiagType="d", threeDim=True, outputCfg=outCfg) #print "mean FCs: ", meanFCs meanFC0Teor = 0.89306075607898694 ratio1 = abs(meanFCs[0] - meanFC0Teor) / meanFC0Teor meanFC1Teor = 0.97448959156755022 ratio2 = abs(meanFCs[1] - meanFC1Teor) / meanFC1Teor ''' print "meanFCs[0]= ", meanFCs[0]
beamRCsect.dir2PositvRebarRows=[reinfLayer] beamRCsect.dir2NegatvRebarRows=[reinfLayer] beamRCsect.creaTwoSections() sections.append(beamRCsect) # Spatial distribution of reinforced concrete # sections (assign RC sections to elements). reinfConcreteSectionDistribution.assign(elemSet=totalSet.getElements,setRCSects=beamRCsect) #Checking shear. lsd.shearResistance.controller= EHE_limit_state_checking.ShearController(limitStateLabel= lsd.shearResistance.label) lsd.shearResistance.controller.analysisToPerform= predefined_solutions.simple_newton_raphson lsd.LimitStateData.check_results_directory= '/tmp/' lsd.normalStressesResistance.outputDataBaseFileName= 'resVerif' outCfg=oc.verifOutVars(listFile='N',calcMeanCF='Y') (FEcheckedModel,meanFCs)= reinfConcreteSectionDistribution.runChecking(lsd.shearResistance, matDiagType="d",threeDim= True,outputCfg=outCfg) #print "mean FCs: ", meanFCs meanFC0Teor= 0.89306075607898694 ratio1= abs(meanFCs[0]-meanFC0Teor)/meanFC0Teor meanFC1Teor= 0.97448959156755022 ratio2= abs(meanFCs[1]-meanFC1Teor)/meanFC1Teor ''' print "meanFCs[0]= ", meanFCs[0] print "ratio1= ",ratio1 print "meanFCs[1]= ", meanFCs[1] print "ratio2= ",ratio2
import os pth = os.path.dirname(__file__) #print "pth= ", pth if (not pth): pth = "." limit_state_data.shearResistance.controller = EHE_limit_state_checking.ShearController( limitStateLabel=limit_state_data.shearResistance.label) limit_state_data.shearResistance.controller.verbose = False # Don't display log messages. limit_state_data.shearResistance.controller.analysisToPerform = custom_newton_raphson limit_state_data.LimitStateData.internal_forces_results_directory = pth + '/' limit_state_data.LimitStateData.check_results_directory = '/tmp/' limit_state_data.normalStressesResistance.outputDataBaseFileName = 'resVerif' outCfg = output_config.verifOutVars(listFile='N', calcMeanCF='Y') (FEcheckedModel, meanFCs) = reinfConcreteSectionDistribution.runChecking( limit_state_data.shearResistance, matDiagType="d", threeDim=True, outputCfg=outCfg) ratio1 = (meanFCs[0] - 0.51922390249173578) / 0.51922390249173578 ratio2 = (meanFCs[1] - 0.51808548496704088) / 0.51808548496704088 ''' print('meanFCs= ',meanFCs) print("ratio1= ",ratio1) print("ratio2= ",ratio2) '''