.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "auto_examples/reliability/form/FORM_linear_function_3d.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code or to run this example in your browser via Binder .. rst-class:: sphx-glr-example-title .. _sphx_glr_auto_examples_reliability_form_FORM_linear_function_3d.py: 2. FORM - Linear function - Three Random variables ==================================================== .. GENERATED FROM PYTHON SOURCE LINES 8-18 In the third example we have the limit state to be a linear function of three (:math:`d=3`) independent Gaussian random variables .. math:: g(X_1, X_2, X_3) = 6.2X_1 -X_2X_3^2 .. math:: \mu_{X_1}=20, \mu_{X_2}=5, \mu_{X_3}=4 .. math:: \sigma_{X_1}=3.5, \sigma_{X_2}=0.8, \sigma_{X_3}=0.4 The probability of failure in this case is :math:`P_f ≈ 0.079` for :math:`\beta = 1.413` .. GENERATED FROM PYTHON SOURCE LINES 23-24 Initially we have to import the necessary modules. .. GENERATED FROM PYTHON SOURCE LINES 27-48 .. code-block:: default from UQpy.run_model.RunModel import RunModel from UQpy.run_model.model_execution.PythonModel import PythonModel from UQpy.distributions import Normal from UQpy.reliability import FORM dist1 = Normal(loc=20., scale=3.5) dist2 = Normal(loc=5., scale=0.8) dist3 = Normal(loc=4., scale=0.4) model = PythonModel(model_script='local_pfn.py', model_object_name="example3",) run_model = RunModel(model=model) form = FORM(distributions=[dist1, dist2, dist3], runmodel_object=run_model) form.run() print('Design point in standard normal space: %s' % form.design_point_u) print('Design point in original space: %s' % form.design_point_x) print('Hasofer-Lind reliability index: %s' % form.beta) print('FORM probability of failure: %s' % form.failure_probability) .. rst-class:: sphx-glr-timing **Total running time of the script:** ( 0 minutes 0.000 seconds) .. _sphx_glr_download_auto_examples_reliability_form_FORM_linear_function_3d.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: binder-badge .. image:: images/binder_badge_logo.svg :target: https://mybinder.org/v2/gh/SURGroup/UQpy/master?urlpath=lab/tree/notebooks/auto_examples/reliability/form/FORM_linear_function_3d.ipynb :alt: Launch binder :width: 150 px .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: FORM_linear_function_3d.py ` .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: FORM_linear_function_3d.ipynb ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_