Closed peterjamesnugent closed 4 years ago
The adapter should include a model settings tab for units. These can be eNums for the following@:
Units are defined in the MCT file as follows:
*UNIT ; Unit System
; FORCE, LENGTH, HEAT, TEMPER
KN , M, BTU, C
This is the pre-amble before any objects are created:
;---------------------------------------------------------------------------
; MIDAS/Civil Text(MCT) File.
; Date : 2018/11/27
;---------------------------------------------------------------------------
*VERSION
8.7.5
*UNIT ; Unit System
; FORCE, LENGTH, HEAT, TEMPER
KN , M, BTU, C
*REBAR-MATL-CODE ; Rebar Material Code
; CONC_CODE, CONC_MDB, SRC_CODE, SRC_MDB
ASTM(RC), Grade 60, ASTM(RC), Grade 60
This should be handled in the adapter.
The key difference between the Lusas_Toolkit and the Midas_Toolkit is that no COM calls are required to create Midas Objects, therefore all methods should be stored in the Engine under the Convert > ToMidas folder.
Given this some thought:
The MidasCivil Adapter should have the following objects that are similar to comlink objects:
midasTextFile
, this will be aList<string>
that has been read from the MCT file (if it is available)directory
, this will be a string
that points to the folder the model is saved. This will be used in the Create methods to write to individual files such as NODES, ELEMENTS etc.The read workflow will look something like this:
The write workflow will look something like this:
When pushing properties that have been assigned there are two ways to achieve the correct assignments.
If the properties has a name (i.e. section properties, materials etc.)
*We can write a generic method to modify the assignment list
If the properties do not have a name (loads, constraints):
; NODE_LIST, CONST(Dx,Dy,Dz,Rx,Ry,Rz), GROUP
When pushing constraints we should create all the boundary groups before pushing the individual constraints - it cannot be a dependecy type because it will just be a string
This is relevant to #7 #8 #9 #11
This is largely complete, anything not covered has separate issues.
We can write the adapter to open a session of Midas but I am not sure how much use this will be as we cannot use it further or to open a specific file.
It might be that we use the adapter to point to a text file or folder where it can read/write.
When pulling the Midas export it is always going to be a single text file. The different features are split with a preceeding , e.g. NODES so it's fairly easy to determine what line nodes start and end on (by searching for the next *).
When pushing to the text files we should do it with several files to make the debugging simpler.