## 3 Methodology
### Retrieval of Cases and Cost Estimation  
After developing the CBR repository, the next step is to apply it to the CBR algorithm. The CBR searches for a previously solved similar problem, retrieves the corresponding solution, adapts the solution to the current problem, verifies the solution, and stores the newly solved problem for future use. In turn, the newly derived solution may be used for solving future problems, which comprises another CBR working cycle. The training in the CBR includes the repository as its base for case selection. A user input is required in the CBR to define a new case. Once the new case is defined, the CBR identifies the best-fitting case from the CBR repository and outputs the properties of that case to the user. After the CBR model is prepared, the CBR case retrieval process begins. The CBR software used for this research is myCBR. The cases are stored in the myCBR software and can be retrieved. The retrieval process begins when the user inputs information regarding the new case. The information provided by the user is the basis of the CBR selection from the repository. After the user provides adequate information, the CBR identifies the case from repository that is the best-fitting case. Once the CBR has identified the best case, the model outputs the estimated cost, which is the final step of the process. In this research, the cost estimation of a window replacement was analyzed. The window properties were obtained and stored in the CBR repository for a new window replacement activity. Considering the information exchange capabilities for the cost estimation in facility management, a research framework is proposed as follows:  
* Existing cost data: Windows installation data are collected and stored in a database. * Data extraction: The database file is read by the prototype model, and the model then collects the desired information from the IFC representation of the BIM. * Visual verification (optional): After the extraction of the geometric and spatial information of the building elements, the BIM is remodeled to quickly visually verify the completeness and accuracy of the model after the geometric transformation. * CBR repository: Next, the extracted information with minimal user-inputted data, such as contractors and weather in the CBR repository, is built with six factors. * Refinement process: If the project cost is acceptable, then the process is stopped. If not, the whole process is reiterated with an appropriate modification to the previous steps. In Figure 5, the first component of obtaining data from an IFC file is related to the general properties of the building component. Line #276 contains the general properties of a window. IFCWALLSTANDARDCASE is the IFC entity name referring to a particular wall. The text within the parenthesis after IFCWALLSTANDARDCASE presents the properties of the wall. The string consisting of a combination of letters and numbers that appears at the beginning and end of the parenthesis is used to identify a particular component. Numbers #16, #184, and #272 refer to other IFC entities that further describe the wall. \"Wall-15\" identifies the wall number within the IFC model. In Figure 5, the second component is the data extraction from an IFC file in IFC materials collection. This step is related to the materials of the wall. The IFC entities related to the materials are in lines #297, #300, #302, #304, and #305. The entity name in line #297 is IFCMATERIAL, which contains the text \"concrete\", which indicates the primary material used for the wall. IFCMATERIALLAYERSET in line #302 lists \"Brick\", which specifies the sub-material of the wall, which could be related to the veneer of the wall. The third component is the collection of data entities. This component identifies the specific location of the element within the IFC model. Lines #311, #315, #319, #322, #325, #329, and #333 are IFC entities that contain the location properties of a wall. Line #311 is the IFCDIRECTION, which is the direction or rotation of the object in the 3D model.