Top Banner
House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 26, 2022 © Selvaag 2008 1 Kristoffer Kvello SELVAAG
35

House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Mar 28, 2015

Download

Documents

Chad Elkin
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

House Designer

Using Knowledge Based Engineering and Lisp to automatically design buildings

Monday, April 10, 2023© Selvaag 2008 1

Kristoffer KvelloSELVAAG

Page 2: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Table of contents

• House Designer (what is it?)• Why Lisp?• Knowledge Based Engineering• Libraries we use• Use of Screamer by House Designer• Some thoughts about using Lisp for this• Users

Page 3: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The company

• Selvaag• One of Norway’s ten largest construction

companies• Around 700 employees

• Selvaag Bluethink• Daughter company writing software• 24 employees

Page 4: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The company

• The Lisp-team– 6 developers

• one of which is the primary author of Movitz and Binary-Types

– http://common-lisp.net/project/movitz/– http://www.cs.uit.no/~frodef/sw/binary-types/

Page 5: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

House Designer

• System for automatic design of apartments and buildings

• Based on sketches from architect/engineer, the system calculates the consequences and fleshes out the design

• And analyzes the results:– cost– statics– heat transfer– light conditions

Page 6: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Main benefits• The problem:

– In designing buildings there is an enormous amount of detail that needs to be remembered and taken into account

– Consequently, errors are often made, leading to costly repairs– Due to the same reason, experimenting with new ideas is time

consuming and costly• House Designer aids the architect by taking care of all aspects

that are considered ”mechanical” (”all” is long-term goal)– reduces errors– allows quick what-if analyses– automatically produces documentation

Page 7: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

One view of the system

User Interface (java)(ca. 75K LOC)

Lisp (Franz’ ACL)

Design++

House Designer code(ca. 288K LOC)

s-expr

xml

database

CAD system

Finite element analysis

Costing engine

Page 8: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.
Page 9: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.
Page 10: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.
Page 11: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

wall types, wall offsets, wall junctions

Page 12: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Where doors are needed, door types, door positions, hinge sides, door directions

Page 13: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Amount, types and positioning of required electrical fixtures

Page 14: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

A valid piping layout (water and ventilation), ensuring that the building is possible to construct

Page 15: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Number of windows required, types, positions

Page 16: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Wheelchair maneouvre space, ensuring that the layout meets government regulations

Page 17: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

SofaOpen plan

Wall extension, automatically generated in order to cover the sofa

Page 18: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.
Page 19: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Why Lisp?

• The use of Lisp was a top management decision from the start

• The company wanted a system to automate knowledge

• The search led to a methodology called Knowledge Based Engineering, and early KBE systems were based on Lisp

• The KBE company emphasised the power of Lisp

Page 20: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Knowledge Based Engineering

• Today KBE has come to mean many things (check wikipedia)

• Best analogy is ”object oriented spreadsheet tightly coupled to a CAD-system”

• Provides handling of dependencies and recalculates what is implicated by a change, just like a spreadsheet

• Lisp projects that seem very similar:• Cells

• http://common-lisp.net/project/cells/• Computed-Class

• http://common-lisp.net/project/computed-class/

Page 21: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Lisp based KBE tools

• Design++ (recently bought by Bentley Systems)– http://dp.com/

• GDL– http://www.genworks.com/

Page 22: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Examples of rules – how to calculate the area of various objects

The area of a window is its width times its height

The area of an apartment is the sum of the area of its internal spaces

The area of an access balcony section is the area it has as a normal space, plus the sum of its lips

Page 23: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Libraries we use

• asdf– http://cclan.cvs.sourceforge.net/cclan/asdf/

• zip– http://common-lisp.net/project/zip/

• clsql 3.6.6– http://clsql.b9.com

• Slime– http://common-lisp.net/project/slime/

Page 24: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Libraries we use

• cl-utilities– http://common-lisp.net/project/cl-utilities/

• s-xml– http://common-lisp.net/project/s-xml/

• aserve– http://opensource.franz.com/aserve/index.html

• expresso 3.1.0– http://exp-engine.sourceforge.net/

• screamer 3.24.1– http://clocc.sourceforge.net/clocc/src/screamer/

Page 25: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The problem of essentiallycyclic relationships

• We have encountered problem domains that are essentially cyclic: there is no natural place to start– positioning of walls, since they are all connected across

floors horizontally and vertically– placement of piping in the service shaft– outlay of prefabricated floor elements

• Engineers start at an arbitrary place and iterate until they find a good solution

• We found we needed backtracking– We also wanted to just start somewhere and get a solution

by trial & error

Page 26: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The problem of essentially cyclic relationships

• The solution was to use Screamer– Ordinary KBE rules create walls based on the

”nominal” borders of spaces– Constraint variables are set up that...

• assert that all walls are aligned with the others they meet

• assert that certain rooms must have a certain area• assert that certain walls (e.g. in vertical shafts) fit each

other vertically• assert that equpment has sufficient wall space

Page 27: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The problem of essentially cyclic relationships

• All these constraints are expressed as demands for offset on each wall from its ”nominal” line, i.e. as numeric variables

• The total set of constraints is handed over to Screamer– Backtracking occurs within what is

to us a black box• When Screamer is done, each

wall will find its values in a table, and the KBE system proceeds as normal

Page 28: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The problem of essentially cyclic relationships

• Piping: part of the problem is establishing how many pipes you need

• Positioning of piping in the service shaft uses Screamer’s backtracking explicitly in the House Designer code: (either 1 2 ..)

Page 29: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

The problem of essentially cyclic relationships

• Not all constraints are necessarily satisfied

• We prioritize them and arrange for the ones with the lowest priority to fail first

• House Designer informs the user which constraints failed

Page 30: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.
Page 31: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Some thoughts about using Lisp for this

• Highlights of what we most appreciate with Lisp:– interactivity: quick recompile, with a living model.

No need to re-run program to reach same state– the break-loop: debugger with restarts– reader macros, allowing us to customize the

syntax of the tool to our liking

Page 32: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Modified syntax

New syntax, defined by means of a reader macro

Original syntax of the KBE tool

Page 33: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Some thoughts about using Lisp for this

• What we most like (cont.)– advice, to customize the tool further– the ease with which one can examine the lisp

image and find out how things work– handler-bind

• Lisp has never been a problem, neither regarding lack of functionality/libraries nor getting the necessary people

Page 34: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Users

• One of our sister companies uses House Designer for statics reports– That branch of the science of mechanics concerned with

forces acting on bodies in equilibrium

• Another sister company is using it to establish consequences of modified governmental regulations

• We are in the process of delivering House Designer to a construction company in the EU

Page 35: House Designer Using Knowledge Based Engineering and Lisp to automatically design buildings Sunday, June 01, 2014© Selvaag 20081 Kristoffer Kvello SELVAAG.

Questions?