⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 weightscode.desc

📁 多学科优化软件isight培训教程初级pdf有很详细的例子讲解
💻 DESC
字号:
MDOLVersion: 6.0
CompilerOptions: warn

Task Airplane

    TaskHeader Airplane
        Version: 1.0
        Evaluation: taskplan
        ControlMode: user
        RunCounter: 1
        BoundsPolicy: adjustvalue
        CheckPoint: unknown
        RandGenInit: default
    End TaskHeader Airplane

    Inputs Airplane
        Parameter: CruiseVel Type: real InitialValue: 0
        Parameter: WingArea Type: real InitialValue: 0
        Parameter: AR Type: real InitialValue: 0
        Parameter: FuseLength Type: real InitialValue: 32.6
        Parameter: FuseDia Type: real InitialValue: 0
        Parameter: WtFuel Type: real InitialValue: 0
        Parameter: WtEng Type: real InitialValue: 0
        Parameter: NumEng Type: integer InitialValue: 0
        Parameter: NumPass Type: integer InitialValue: 0
        Parameter: WtPayload Type: real InitialValue: 0
        Parameter: WingSpan Type: real
        Parameter: WingChord Type: real
    End Inputs Airplane

    Outputs Airplane
        Parameter: LoadedWt Type: real
    End Outputs Airplane

    SimCode WeightsCode

        InputFiles WeightsCode
            FileDescription WeightsIntxt
                FileType: standard
                TemplateFile: "WeightsInTemp.dat"
                InputFile: "WeightsIn.txt"
                Parameters
                    CruiseVel WingArea AR FuseLength FuseDia WtFuel WtEng NumEng NumPass WtPayload
                Instructions
                    find "vel = " ignore 
                    replace word with $CruiseVel 
                    find "Swing = " ignore 
                    replace word with $WingArea 
                    find "AR = " ignore 
                    replace word with $AR 
                    find "Length = " ignore 
                    replace word with $FuseLength 
                    find "Diameter = " ignore 
                    replace word with $FuseDia 
                    find "Wfuel = " ignore 
                    replace word with $WtFuel 
                    find "Wen =" ignore 
                    replace word with $WtEng 
                    find "Nen = " ignore 
                    replace word with $NumEng 
                    find "Npass = " ignore 
                    replace word with $NumPass 
                    find "Wpay =" ignore 
                    replace word with $WtPayload
                End Instructions
            End FileDescription WeightsIntxt
        End InputFiles WeightsCode

        OutputFiles WeightsCode
            FileDescription WeightsOuttxt
                FileType: standard
                OutputFile: "WeightsOut.txt"
                Parameters
                    LoadedWt
                Instructions
                    find "Total Weight of Loaded Aircraft (lbs.)       = " ignore 
                    read LoadedWt as "%g"
                    provide $LoadedWt
                End Instructions
            End FileDescription WeightsOuttxt
        End OutputFiles WeightsCode

        SimCodeProcess WeightsCode
            Program: "../Programs/weights.exe"
            ProcessType: transient
            ElapseTime: 5m
            Prologue
                WriteInputSpecs: WeightsIntxt
            Epilogue
                ReadOutputSpecs: WeightsOuttxt
            Execution: "$Program"
        End SimCodeProcess WeightsCode

    End SimCode WeightsCode

    TaskProcess Airplane
        Control: [
            WeightsCode
        ]
    End TaskProcess Airplane

    Optimization Airplane
        PotentialVariables:
            CruiseVel WingArea AR FuseLength FuseDia WtFuel WtEng NumEng NumPass WtPayload
        Variables:
            WingArea FuseLength FuseDia
        VariableScaling
            Parameter: WingArea ScaleFactor: 1.0
            Parameter: FuseLength ScaleFactor: 1.0
            Parameter: FuseDia ScaleFactor: 1.0
        InputConstraints
        PotentialObjectives:
            CruiseVel WingArea AR FuseLength FuseDia WtFuel WtEng NumEng NumPass WtPayload
            LoadedWt
        OutputConstraints
    End Optimization Airplane

    DataStorage Airplane
        Restore: no
        DataLog: "Airplane.db" Mode: overwrite
        Levels: all
        StoreGradRuns: yes
        StoreApproxRuns: yes
    End DataStorage Airplane

End Task Airplane

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -