def __init__(self, analysis_obj):
        super(CfdCaseWriterFoam, self).__init__()
        """ analysis_obj should contains all the information needed,
        boundaryConditionList is a list of all boundary Conditions objects(FemConstraint)
        """

        self.analysis_obj = analysis_obj
        self.solver_obj = CfdTools.getSolver(analysis_obj)
        self.physics_model, isPresent = CfdTools.getPhysicsModel(analysis_obj)
        self.mesh_obj = CfdTools.getMesh(analysis_obj)
        self.material_objs = CfdTools.getMaterials(analysis_obj)
        self.bc_group = CfdTools.getCfdBoundaryGroup(analysis_obj)
        self.initial_conditions, isPresent = CfdTools.getInitialConditions(
            analysis_obj)
        self.porousZone_objs, self.porousZonePresent = CfdTools.getPorousObjects(
            analysis_obj)
        self.alphaZone_objs = CfdTools.getAlphaObjects(analysis_obj)
        self.zone_objs = CfdTools.getZoneObjects(analysis_obj)
        self.mesh_generated = False

        self.signals = CfdCaseWriterSignals()

        if len(self.alphaZone_objs) > 0:
            self.physics_model['Time'] = 'Transient'
            # TODO: remove this code and add GUI support for transient simulations
            self.solver_obj.TimeStep = 0.001
            self.solver_obj.WriteInterval = 0.05
            self.solver_obj.EndTime = 1
Exemple #2
0
 def __init__(self, analysis_obj):
     self.analysis_obj = analysis_obj
     self.solver_obj = CfdTools.getSolver(analysis_obj)
     self.physics_model = CfdTools.getPhysicsModel(analysis_obj)
     self.mesh_obj = CfdTools.getMesh(analysis_obj)
     self.material_objs = CfdTools.getMaterials(analysis_obj)
     self.bc_group = CfdTools.getCfdBoundaryGroup(analysis_obj)
     self.initial_conditions = CfdTools.getInitialConditions(analysis_obj)
     self.porousZone_objs = CfdTools.getPorousZoneObjects(analysis_obj)
     self.initialisationZone_objs = CfdTools.getInitialisationZoneObjects(analysis_obj)
     self.zone_objs = CfdTools.getZoneObjects(analysis_obj)
     self.mesh_generated = False
     self.working_dir = CfdTools.getOutputPath(self.analysis_obj)
Exemple #3
0
 def __init__(self, analysis_obj):
     self.analysis_obj = analysis_obj
     self.solver_obj = CfdTools.getSolver(analysis_obj)
     self.physics_model, isPresent = CfdTools.getPhysicsModel(analysis_obj)
     self.mesh_obj = CfdTools.getMesh(analysis_obj)
     self.material_objs = CfdTools.getMaterials(analysis_obj)
     self.bc_group = CfdTools.getCfdBoundaryGroup(analysis_obj)
     self.initial_conditions, isPresent = CfdTools.getInitialConditions(analysis_obj)
     self.porousZone_objs = CfdTools.getPorousZoneObjects(analysis_obj)
     self.initialisationZone_objs = CfdTools.getInitialisationZoneObjects(analysis_obj)
     self.zone_objs = CfdTools.getZoneObjects(analysis_obj)
     self.conversion2D_obj,self.conversionObjPresent = CfdTools.get2DConversionObject(analysis_obj)
     self.mesh_generated = False
    def __init__(self, analysis_obj):
        super(CfdCaseWriterFoam, self).__init__()

        self.analysis_obj = analysis_obj
        self.solver_obj = CfdTools.getSolver(analysis_obj)
        self.physics_model, isPresent = CfdTools.getPhysicsModel(analysis_obj)
        self.mesh_obj = CfdTools.getMesh(analysis_obj)
        self.material_objs = CfdTools.getMaterials(analysis_obj)
        self.bc_group = CfdTools.getCfdBoundaryGroup(analysis_obj)
        self.initial_conditions, isPresent = CfdTools.getInitialConditions(
            analysis_obj)
        self.porousZone_objs = CfdTools.getPorousZoneObjects(analysis_obj)
        self.initialisationZone_objs = CfdTools.getInitialisationZoneObjects(
            analysis_obj)
        self.zone_objs = CfdTools.getZoneObjects(analysis_obj)
        self.mesh_generated = False

        self.signals = CfdCaseWriterSignals()