Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·...

39
© 2013 ANSYS, Inc. September 27, 2013 1 Release 14.5 14. 5 Release Introduction to ANSYS DesignXplorer Lecture 4 Response Surface

Transcript of Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·...

Page 1: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 1 Release 14.5

14. 5 Release

Introduction to ANSYS DesignXplorer

Lecture 4 Response Surface

Page 2: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 2 Release 14.5

• Response Surfaces are functions of different nature where the output parameters are described in terms of the input parameters

• Response Surfaces provide the approximated values of the output parameters, everywhere in the analyzed design space, without the need to perform a complete solution

• The response surface methods described here are suitable for problems using ~10-15 input parameters

Standard Response

Surface / Kriging Neural Network Non-parametric Regression

Response Surface

Page 3: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 3 Release 14.5

1. Response Surface Procedure

2. Response Surface Types

Response Surface Outline

Page 4: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 4 Release 14.5

1. Create response surface (3D)

A

B

C

Response Surface Procedure

Page 5: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 5 Release 14.5

1. Create response surface

– 2D:1 output parameter vs. 1 input parameter

– 2D Slices: 1 output parameter vs. 2 input parameter (each curve represents a “slice” of the response)

Response Surface Procedure

Page 6: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 6 Release 14.5

2. Check goodness of fit by displaying design points on response chart

Response Surface Procedure

Page 7: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 7 Release 14.5

• Coefficient of Determination (R2 measure):

– Measures how well the response surface represents output parameter variability.

– Should be as close to 1.0 as possible.

• Adjusted Coefficient of Determination:

– Takes the sample size into consideration when computing the Coefficient of Determination.

– Usually this is more reliable than the usual coefficient of determination when the number of samples is small ( < 30).

• Maximum Relative Residual:

– Similar measure for response surface using alternate mathematical representation.

– Should be as close to 0.0 as possible.

Equations in Appendix

Response Surface Procedure

3. Check goodness of fit by reviewing goodness of fit metrics

Page 8: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 8 Release 14.5

• Root mean square error:

– Square root of the average square of the residuals at the DOE points for regression methods.

• Relative Root Mean Square Error:

– Square root of the average square of the residuals scaled by the actual output values at the DOE points for regression methods.

• Relative Maximum Absolute Error:

– Absolute maximum residual value relative to the standard deviation of the actual outputs.

• Relative Average Absolute Error:

– The average of error relative to the standard deviation of the actual output data

– Useful when the number of samples is low ( < 30).

Equations in Appendix

Response Surface Procedure

3. Check goodness of fit by reviewing goodness of fit metrics

Page 9: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 9 Release 14.5

2nd Order

Polynomial

Kriging

Response Surface Procedure

4. Check goodness of fit by reviewing Predicted versus Observed Chart

Page 10: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 10 Release 14.5

• Compare the predicted and observed values of the output parameters at different locations of the design space

• Can be added when defining the response surface or by right-clicking on the response surface plot

• It is needed for Kriging and Sparse Grid response surfaces since the standard goodness of fit metrics over predict goodness of fit

Response Surface Procedure

5. Check goodness of fit by creating verification points

Page 11: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 11 Release 14.5

– Select a more appropriate response surface type (discussed later)

– Manually add Refinement Points: Points which are to be solved to improve the response surface quality in this area of the design space.

Response Surface Procedure

6. Improve response surface

Page 12: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 12 Release 14.5

– Response Point: a snapshot of parameter values where output parameter values were calculated in ANSYS DesignXplorer from a Response Surface.

– Spider plot

- A visual representation of the output

parameter values relative to the range of

that parameter given a specified

scenario (input parameters values)

Response Surface Procedure

7. Extract data

Page 13: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 13 Release 14.5

– Local Sensitivity Bar plot

• The change of the output based on the change of each input independently

– Local Sensitivity Pie chart

– The relative impact of the input parameters on the local sensitivity

avgOutput

OutputOutput minmax

Response Surface Procedure

7. Extract data

Page 14: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 14 Release 14.5

– Local Sensitivity Curves

• Show sensitivity of one or two output parameter to the variations of one input parameter while all other input parameters are held fixed

• When plotting two output parameters, the circle corresponds to the lowest value of each parameter

• Manufacturable values are supported (green squares)

Response Surface Procedure

7. Extract data

Page 15: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 15 Release 14.5

– Min-Max Search: The Min-Max Search examines the entire output parameter space from a Response Surface to approximate the minimum and maximum values of each output parameter

Response Surface Procedure

7. Extract data

Page 16: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 16 Release 14.5

– Response Surface

Response Surface Procedure

7. Extract data

Page 17: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 17 Release 14.5

Review • Design Point – A scenario to be solved. Either selected manually or

automatically by Parameter Correlation and Design of Experiments

• Verification Point – A scenario to be solved that is used to determine the accuracy of a response surface

• Refinement Point – A scenario to be solved that is used to improve a response surface

• Response Point – The predicted behavior for a scenario based on the response surface

Page 18: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 18 Release 14.5

• There are five response surface types in DX

1. Standard Response Surface (2nd order polynomial) [default]

2. Kriging

3. Non-parametric Regression

4. Neural Network

5. Sparse Grid

DOE

samples

2nd

order

Kriging

Neuronal network Neuronal network

Non parametric

regression

Response Surface Types

Page 19: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 19 Release 14.5

• This is the default response surface type and a good starting point

• Based on a modified quadratic formulation

Output=f(inputs)

where f is a second order polynomial

• Will provide satisfactory results when the variation of the output parameters is mild/smooth

DOE samples

2nd order

f(X)

Response Surface Standard Full 2nd Order Polynomials

Page 20: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 20 Release 14.5

• A multidimensional interpolation combining a polynomial model similar to the one of the standard response surface, which provides a “global” model of the design space, plus local deviations determined so that the Kriging model interpolates the DOE points.

Output=f(inputs) + Z(inputs) where f is a second order polynomial (which dictates the “global” behaviour of the model) and Z a perturbation term (which

dictates the “local” behaviour of the model)

• Since Kriging fits the response surface through all design points the Goodness of fit metrics will always be good

y(X) f(X)

Z(X) : “localized” deviations

DOE

samples

Kriging

Response Surface Kriging

Page 21: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 21 Release 14.5

• Will provide better results than the standard response surface when the variations of the output parameters is stronger and non-linear (e.g. EMAG)

• Do not use when results are noisy

• Kriging interpolates the Design Points, but oscillations appear on the response surface

Response Surface Kriging

Page 22: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 22 Release 14.5

• Allows DX to determine the accuracy of the response surface as well as the points that would be required to increase the accuracy

• Refinement Type

– Automatic: ANSYS DesignXplorer will add samples to the DOE (number of additional samples is user controlled)

– Manual: User specifies samples

Response Surface Kriging Refinement

Page 23: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 23 Release 14.5

With 2 refinement

points generated

through auto-

refinement

Initial DOE Samples

Response Surface Kriging Refinement

Page 24: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 24 Release 14.5

• Belongs to a general class of Support Vector Method (SVM) type techniques

• The basic idea is that the tolerance epsilon creates a narrow envelope around the true output surface and all or most of the sample points must/should lie inside this envelope.

f(X): Response surface with a margin of

tolerance

f(X) +

f(X) -

Response Surface Non-parametric Regression

Page 25: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 25 Release 14.5

• Suited for nonlinear responses

• Use when results are noisy (discussed on next slide)

• for some problem types (like ones dominated by flat surfaces or lower order polynomials), some oscillations may be noticed between the DOE points

• Usually slow to compute

• Suggested to only use when goodness of fit metrics from the quadratic response surface model is unsatisfactory

DOE samples Non parametric

regression

Response Surface Non-parametric Regression

Page 26: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 26 Release 14.5

NPR approximates the Design Points with a margin of tolerance

Kriging interpolates the Design Points, but oscillations appear on the response surface

NPR vs Kriging when results are noisy

Page 27: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 27 Release 14.5

• Mathematical technique based on the natural neural network in the human brain

• Each arrow is associated with a

weight (this determines whether a

hidden function is active)

• Hidden functions are threshold

functions which turn off or on

based on sum of inputs

•With each iteration, weights are

adjusts to minimize error between

response surface and design

points

Detailed Explanation in Appendix

Response Surface Neural Network

Page 28: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 28 Release 14.5

• Successful with highly nonlinear responses

• Control over the algorithm is very limited

• Only use in rare case

DOE samples Neuronal network Neuronal network

Response Surface Neural Network

Page 29: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 29 Release 14.5

• An adaptive response surface (it refines itself automatically)

• Usually requires more runs than other response surfaces so use when solve is fast

• Requires the “Sparse Grid Initialization” DOE as a starting point

• Only refines in the directions necessary so fewer design points are needed for the same quality response surface

5

17

Refinement continues (DPs are

added) until Max Relative Error

or Maximum depth is reached

for each response.

Response Surface Sparse Grid

Page 30: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 30 Release 14.5

• Maximum Depth – The maximum number of hierarchical interpolation levels to compute in each direction

Response Surface Sparse Grid

Page 31: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 31 Release 14.5

• Adjust the Max Relative Error and the convergence can continue

Response Surface Sparse Grid

Page 32: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 32 Release 14.5

Summary • Standard Response Surface 2nd-Order Polynomial (default)

– Effective when the variation of the output is smooth with regard to the input parameters.

• Kriging

– Efficient in a large number of cases.

– Suited to highly nonlinear responses.

– Do NOT use when results are noisy; Kriging is an interpolation that matches the points exactly.

– Always use verification points to check Goodness of Fit.

• Non-Parametric Regression

– Suited to nonlinear responses.

– Use when results are noisy.

– Typically slow to compute.

• Neural Network

– Suited to highly nonlinear responses.

– Use when results are noisy.

– Control over the algorithm is very limited.

• Sparse Grid

– Suited for studies containing discontinuities.

– Use when solve is fast.

Good default choice: Kriging with auto-refinement

Page 33: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 33 Release 14.5

Problem Description This workshop looks deeper into the options available for DOEs, Response Surfaces

and Optimization, as well as exposes you to creating parameters in FLUENT and CFD-Post.

The problem to be analyzed is a static mixer where hot and cold fluid, entering at variable velocities, mix. The objective of this analysis is to find inlet velocities which minimize pressure loss from the cold inlet to the outlet and minimize the temperature spread at the outlet.

Input

• Hot inlet velocity

• Cold inlet velocity

Output

• Pressure loss

• Temperature spread

Cold Inlet 300 K

Hot Inlet 400 K

Outlet

Page 34: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 34 Release 14.5

Appendix

Page 35: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 35 Release 14.5

Goodness of fit metrics

Coefficient of

Determination

Adjusted Coefficient

of Determination

Maximum Relative

Residual

Page 36: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 36 Release 14.5

Goodness of fit metrics

Root Mean Square

Error

Relative Maximum

Absolute Error

Relative Average

Absolute Error Relative Root Mean

Square Error

Page 37: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 37 Release 14.5

Non-Parametric regression (NPR) Surface approximation method • W: weighting vector • X: input sample (DOE) • b: bias • K: Gaussian Kernel (=Radial Basis Function) • A: Lagrange Multipliers • N: number of DOE points A and b are the unknown parameters

Using the Support Vector Machine (SVM) technique • Support vectors are the subset of X which is deemed to represent the output parameter:

• Up until a threshold the error is considered 0, after the error it becomes calculated as “error-epsilon”

high nonlinear behavior of the outputs with respect to the inputs can be captured

N

i

iii bXXKAAbXWXf1

*),(*)(,)(

00/];1[,* iii AorANiX

f(X): Response surface with a margin of

tolerance

f(X) +

f(X) -

Page 38: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 38 Release 14.5

Neural Network “A network of weighted, additive values with nonlinear transfer functions”

http://www.dtreg.com/mlfn.htm

ijij xwu )exp(1

)exp(1

2tanh

j

jj

ju

uu

jjj uh

yk compared

with yDP. Weight

functions

adjusted to

minimize error

Page 39: Introduction to ANSYS DesignXplorer - ttu.eeinnomet.ttu.ee/martin/MER0070/WB/WS10/DX_14.5_L04... ·  · 2014-04-08Introduction to ANSYS DesignXplorer Lecture 4 ... (2nd order polynomial)

© 2013 ANSYS, Inc. September 27, 2013 39 Release 14.5

Sparse Grid Iteration Procedure (animation)