コード例 #1
0
ファイル: rna.py プロジェクト: TanujTanmay/WINDOW_openMDAO
        01.36, 06.83, 10.25, 14.35, 22.55, 26.65, 34.85, 43.05
    ]
    prob['span_airfoil_id'] = [0, 1, 2, 3, 4, 5, 6, 7]
    prob['pitch'] = 0.0
    prob['thickness_factor'] = 1.0
    prob['shaft_angle'] = -5.0
    prob['cut_in_speed'] = 3.0
    prob['cut_out_speed'] = 25.0
    prob['machine_rating'] = 5000.0
    prob['drive_train_efficiency'] = 1.0
    #prob['overhang'] = 5.0
    prob['gear_ratio'] = 96.76
    prob['Np'] = [3, 3, 1]
    #prob['gearbox_cm_x'] = 0.1
    #prob['tower_top_diameter'] = 3.78

    prob.run_model()
    print 'Executed in ' + str(round(time() - start, 2)) + ' seconds\n'

    # print outputs
    var_list = ['rotor_mass', 'nacelle_mass', 'cost_rna', 'tip_deflection', 'span_stress_max', \
                'rotor_cp', 'rotor_ct', 'rotor_torque', 'rotor_thrust', \
                'rated_wind_speed', 'wind_bin', 'elec_power_bin', 'ct_bin', \
                'scale.hub_height', 'scale.turbine_rated_current', 'scale.solidity_rotor', \
                'rna_mass']
    saved_output = {}
    for v in var_list:
        saved_output[v] = prob[v]

    beautify_dict(saved_output)
コード例 #2
0
            'span_r' : span_r, \
            'span_dr' : span_dr, \
            'span_chord' :  span_chord, \
            'span_twist' : span_twist, \
            'span_airfoil' : span_airfoil,\
            'pitch': 0}
    outputs={}
    
    model = BEM(num_nodes=20, rho_air=1.225)
    
    start = time()  
    model.compute(inputs, outputs)  
    print 'Executed in ' + str(round(time() - start, 2)) + ' seconds'
    
    
    ###################################################
    ############### Post Processing ###################
    ################################################### 
    beautify_dict(inputs) 
    print '-'*10
    beautify_dict(outputs)