Jump to content

How To Create a Response Surface in 4 Easy Steps

response surface model

Response surfaces, also known as sur­ro­gate models or meta models, are nowadays often used whenever the eval­u­a­tion of a function is not directly possible or simply too expen­sive. In the context of engi­neer­ing and sim­u­la­tion, a typical appli­ca­tion is the use of response surfaces instead of expen­sive CFD com­pu­ta­tions. The sim­u­la­tion of new design can­di­dates, such as a new ship hull shape or a new aircraft wing design, can take hours or even days to complete. Nat­u­rally, fully auto­mated and com­pre­hen­sive design opti­miza­tion is then out of reach.

Sim­u­la­tions can take hours or even days to complete. How can we effi­ciently find an optimal design?

To overcome this barrier, the idea is to simulate only a suf­fi­ciently small number of samples and create a response surface based on this pre-computed or exper­i­men­tal data. With such a response surface, one can effi­ciently run further studies or opti­miza­tions with thou­sands of function calls without trig­ger­ing the expen­sive sim­u­la­tion code again. Famous math­e­mat­i­cal approaches for response surfaces are poly­no­mial models, kriging (Gaussian process), radial basis func­tions and neural networks. So how can we now create and employ such a response surface in CAESES®, based on an existing data set with samples for variable and function values? 

Step #1: Create a new project

Open CAESES® and save a new project some­where to your PC. Everyone can probably handle this step ;-)

Save a new CAESES project

Step #2: Provide the data base

Now we need a data base with samples that gives us the variable values along with the cor­re­spond­ing function values i.e existing eval­u­a­tions. For instance, this could be shape para­me­ters along with some CFD or other sim­u­la­tion results. We keep the format simple: just provide an ASCII file with N rows where the variable values are listed, followed by the eval­u­a­tions. Here is an example with N=16 samples, 2 vari­ables and 1 objec­tive function (which is given in the last column):

Provide a simple data base as ASCII file - each row represents 1 sample data

Put this file into the current project direc­tory, i.e. where you stored your project file. That’s all for the data base. 

Step #3: Create the response surface

Use our response surface feature and drag & drop it into the graph­i­cal user inter­face so that it appears in the object tree of CAESES®.

Create response surface object in the tree

Step #4: Perform a cal­cu­la­tion on the response surface

In the next step, enter your variable values into the editor for which you want to receive the cal­cu­lated function value. Note that we use the list syntax with the brackets ([element1, element2,…]). In our example, we enter two values for the two vari­ables, respectively.

Enter variable values to perform a calculation on the response surface

Trigger the creation of the model and the function eval­u­a­tion either through the context menu, or through the green play” button at the top of the window (there won’t be music starting up by pressing this button, just FYI …).

Perform the evaluation on the response surface

That’s it. The result is now imme­di­ately given in the tree when you expand the RSM”-node:

 The evaluations are finally given as a list, which in our basic example is a single value

For this blog post, we used some sort of multi-model approach where several dif­fer­ent response surface models are checked auto­mat­i­cally. The one with the best fit is finally taken for per­form­ing the eval­u­a­tion. By gen­er­at­ing a set of dif­fer­ent metrics such as absolute errors, mean values, R2 etc., you can option­ally control how to pick the model. 

What’s Next?

At this stage, you have a very basic editor to enter your variable values (and it’s a bit boring and tedious to manually enter the values). Hence, as a next step, you would create design variable objects and para­me­ters for your eval­u­a­tion, see the screen­shot below. This allows you to run further auto­mated studies or formal opti­miza­tions with CAESES® on the response surface. For fully auto­mated sur­ro­gate-based opti­mizia­tion in CAESES® with design engines, you can also check out the post Global Opti­miza­tion using Response Surfaces

Introduce parameters and design variables, e.g. for automated studies

More articles

Latest from the blog

All articles

Stay up to date

Receive latest news to your inbox.

Subscribe to newsletter