コード例 #1
0
 def __init__(self):
     description = """Starts the MetaServer"""
     PyFoamApplication.__init__(self,
                                description=description,
                                usage="%prog",
                                interspersed=True,
                                nr=0)
    def __init__(self,
                args=None,
                 **kwargs):
        description="""\
This utility extrudes  2D blockMeshDict to 3DblockMeshDict appropriate for OpenFOAM blockMesh utility. Application requires a blockMesh2D file representing
        the two dimensional domain and converts it to 3D domain by extruding or rotating the domain.
                """
        examples="""\
%prog blockMeshDict2D --extrude --distance-front=0.2 --distance-back=0.2 --division=10

  Extrudes the 2D-mesh by 0.5 on both sides (with 10 divisions) and writes it to blockMeshDict

%prog blockMeshDict2D --y-rotate --angle-front=5 --angle-back=5  --print

  Rotates around the y-axis with and angle of 5 degree on both sides and prints the result to the console
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   examples=examples,
                                   usage="%prog <blockMeshDict2D>",
                                   changeVersion=False,
                                   nr=1,
                                   interspersed=True,
                                   subcommands=False,
                                   **kwargs)
コード例 #3
0
    def __init__(self,args=None):
        description="""\
Clone an Eulerian case. The directories 'domain' and
'lagrangian.org' are copied. The shell scripts to run the simulation
are also copied.\n
\n
Most files are copied using symlinks. The following\n
files are replaced by a copy of the original.\n
\n
domain/0.org\n
lagrangian.org/0.org\n
domain/system/controlDict\n
domain/system/fvSchemes\n
domain/system/fvSolution\n
domain/constant/polyMesh/blockMeshDict\n
domain/constant/polyMesh/blockMeshDict\n
config_vars\n
geometricData\n
initialConditions\n
simParams.json\n
.gitignore"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog [options] <source caseDirectory> <destination caseDirectory>",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=2)
コード例 #4
0
    def __init__(self):
        description="""\
Lists all the processes known to a meta-server
        """
        self.defaultHost=config().get("Metaserver","ip")
        self.defaultPort=config().getint("Metaserver","port")

        PyFoamApplication.__init__(self,description=description,usage="%prog [options]",interspersed=True,nr=0)
コード例 #5
0
ファイル: pyFoamNetList.py プロジェクト: floli/tools
    def __init__(self):
        description = """\
Lists all the processes known to a meta-server
        """
        self.defaultHost = config().get("Metaserver", "ip")
        self.defaultPort = config().getint("Metaserver", "port")

        PyFoamApplication.__init__(self, description=description, usage="%prog [options]", interspersed=True, nr=0)
コード例 #6
0
    def __init__(self):
        description = """\
Connects to a running pyFoam-Server and executes commands via remote
procedure calls
        """
        PyFoamApplication.__init__(self,
                                   description=description,
                                   usage="%prog <host> <port>",
                                   interspersed=True,
                                   nr=2)
コード例 #7
0
    def __init__(self,args=None):
        description="""
Change MixingPlane boundary condition parameters
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseDirectory> mixingPlanePatchName",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=2)
コード例 #8
0
    def __init__(self, args=None):
        description = """
Change MixingPlane boundary condition parameters
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseDirectory>",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=1)
コード例 #9
0
    def __init__(self,args=None):
        description="""\
Change GGI boundary condition parameters
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseDirectory> ggiPatchName",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=2)
コード例 #10
0
ファイル: RedoPlot.py プロジェクト: floli/tools
    def __init__(self):
        description="""\
Either connects to a running pyFoam-Server and gets all the
information for plotting or reads the relevant data from a pickle file
and either displays the plot or writes the plots to file
        """
        PyFoamApplication.__init__(self,
                                   description=description,
                                   usage="%prog [options] (<host> <port>|<pickleFile>)",
                                   interspersed=True,
                                   nr=1,
                                   exactNr=False)
コード例 #11
0
ファイル: Execute.py プロジェクト: martinep/foam-extend-svn
    def __init__(self,args=None):
        description="""\
Runs a command, but first switches the environment to a specific
OpenFOAM-version. Is of use for using wmake for a specific version
        """
        
        PyFoamApplication.__init__(self,
                                   nr=1,
                                   exactNr=False,
                                   args=args,
                                   usage="%prog [options] <command> [arguments]",
                                   description=description)
コード例 #12
0
ファイル: APoMaFoXiiQt.py プロジェクト: minhbau/PyFoam
    def __init__(self, args=None):
        description = """\
APoMaFoX is "A Poor Mans FoamX".

A small text interface to the CaseBuilder-Functionality
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseBuilderFile>",
                                   interspersed=True,
                                   nr=0,
                                   exactNr=False)
コード例 #13
0
    def __init__(self,args=None):
        description="""\
APoMaFoX is "A Poor Mans FoamX".

A small text interface to the CaseBuilder-Functionality
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseBuilderFile>",
                                   interspersed=True,
                                   nr=0,
                                   exactNr=False)
コード例 #14
0
    def __init__(self, args=None):
        description = """
Init MixingPlane boundary condition parameters
"""
        PyFoamApplication.__init__(
            self,
            args=args,
            description=description,
            usage=
            "%prog <caseDirectory> mixingPlane_MasterPatchName mixingPlane_ShadowPatchName",
            interspersed=True,
            changeVersion=False,
            nr=3)
コード例 #15
0
ファイル: DisplayBlockMesh.py プロジェクト: minhbau/PyFoam
    def __init__(self):
        description="""\
Reads the contents of a blockMeshDict-file and displays the vertices
as spheres (with numbers). The blocks are sketched by lines. One block
can be seceted with a slider. It will be displayed as a green cube
with the local directions x1,x2 and x3. Also a patch that is selected
by a slider will be sketched by blue squares.  This implementation
uses Tkinter and is no longer activly developed.  Use the QT-version.
        """
        PyFoamApplication.__init__(self,
                                   description=description,
                                   usage="%prog [options] <blockMeshDict>",
                                   interspersed=True,
                                   nr=1)
コード例 #16
0
    def __init__(self,args=None):
        description="""
Init GGI boundary condition parameters in boundary file.
Init GGI boundary fields in time directories.
Generate faceSet scripts for ggi zones.
Modify GGI zones information in decomposeParDict file.
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog <caseDirectory> ggi_MasterPatchName ggi_ShadowPatchName",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=3)
コード例 #17
0
    def __init__(self, args=None, **kwargs):

        description = """
            Some description needed
            """
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   usage="%prog [<directories>]",
                                   interspersed=True,
                                   changeVersion=False,
                                   nr=0,
                                   exactNr=False,
                                   **kwargs)
コード例 #18
0
ファイル: Execute.py プロジェクト: WarnerChang/PyFoam
    def __init__(self, args=None, **kwargs):
        description = """\
Runs a command, but first switches the environment to a specific
OpenFOAM-version. Is of use for using wmake for a specific version
        """

        PyFoamApplication.__init__(
            self,
            nr=1,
            exactNr=False,
            args=args,
            usage="%prog [options] <command> [arguments]",
            description=description,
            **kwargs)
コード例 #19
0
ファイル: cloneCase.py プロジェクト: ahmmedshakil/O2RBC
    def __init__(self, args=None):
        description = """
Clone an graph case in the CBF framework. The directories 'domain'
'RBC' and 'RBCSource' are copied. The shell scripts to run the simulation
are also copied.\n
Files can be copied using symlinks.
"""
        PyFoamApplication.__init__(
            self,
            args=args,
            description=description,
            usage=
            "%prog [options] <source caseDirectory> <destination caseDirectory>",
            interspersed=True,
            changeVersion=False,
            nr=2)
コード例 #20
0
    def __init__(self, args=None):
        description = """\
Copies the contents of the last time-step of the source case to the
first time-step of the destination case (thus using it as initial
conditions). 

Additionally, copies the Lagrangian meshes and the RBC meshes of the 
source directory to the destination case."""
        PyFoamApplication.__init__(
            self,
            args=args,
            description=description,
            usage=
            "%prog [options] <source caseDirectory> <destination caseDirectory>",
            interspersed=True,
            changeVersion=False,
            nr=2)
コード例 #21
0
    def __init__(self, args=None, **kwargs):
        description = """\
Either connects to a running pyFoam-Server and gets all the
information for plotting or reads the relevant data from a pickle file
and either displays the plot or writes the plots to file
        """
        if args:
            self.quiet = True
        else:
            self.quiet = False

        PyFoamApplication.__init__(
            self,
            args=args,
            description=description,
            usage="%prog [options] (<host> <port>|<pickleFile>)",
            interspersed=True,
            nr=1,
            exactNr=False,
            **kwargs)
コード例 #22
0
    def __init__(self, args=None, **kwargs):
        description = """\
This utility extrudes  2D blockMeshDict to 3DblockMeshDict appropriate for OpenFOAM blockMesh utility. Application requires a blockMesh2D file representing
        the two dimensional domain and converts it to 3D domain by extruding or rotating the domain.
                """
        examples = """\
%prog blockMeshDict2D --extrude --distance-front=0.2 --distance-back=0.2 --division=10

  Extrudes the 2D-mesh by 0.5 on both sides (with 10 divisions) and writes it to blockMeshDict

%prog blockMeshDict2D --y-rotate --angle-front=5 --angle-back=5  --print

  Rotates around the y-axis with and angle of 5 degree on both sides and prints the result to the console
"""
        PyFoamApplication.__init__(self,
                                   args=args,
                                   description=description,
                                   examples=examples,
                                   usage="%prog <blockMeshDict2D>",
                                   changeVersion=False,
                                   nr=1,
                                   interspersed=True,
                                   subcommands=False,
                                   **kwargs)
コード例 #23
0
 def __init__(self):
     description = """Starts the MetaServer"""
     PyFoamApplication.__init__(self, description=description, usage="%prog", interspersed=True, nr=0)
コード例 #24
0
ファイル: pyFoamNetShell.py プロジェクト: floli/tools
    def __init__(self):
        description="""\
Connects to a running pyFoam-Server and executes commands via remote
procedure calls
        """
        PyFoamApplication.__init__(self,description=description,usage="%prog <host> <port>",interspersed=True,nr=2)