jbjares

Untitled

Feb 11th, 2016
343
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 26.45 KB | None | 0 0
  1. package eu.sifem.utils;
  2. ===================================================================================================================
  3. Constant.java
  4. ======================
  5. #
  6.  
  7.  
  8. public class Constant {
  9. /* pak configs parameters*/
  10. public class PAKSolver{
  11. public static final String DIV_L="Division L"; //
  12. public static final String DIV_B="Division B";
  13. public static final String DIV_W="Division W";
  14. public static final String DIV_H="Division H";
  15. public static final String DIV_h="Division h";
  16. public static final String LENGTH="Length";
  17. public static final String HEIGHT="Height";
  18. public static final String WIDTH="Width";
  19. public static final String WIDTH_OF_BM="Width of BM";
  20. public static final String THICKNESS="Thickness (h)";
  21. public static final String LOAD_FREQUENCY="Load Frequency";
  22. public static final String LOAD_VALUE="Load Value";
  23. public static final String DENSITY_RHO="Density RHO";
  24. public static final String SPEED_OF_SOUND_C="Speed of sound (C)";
  25. public static final String YOUNG_MODULUS="Young Modulus";
  26. public static final String DAMPING="Damping";
  27. public static final String DISP_X="DISP_X";
  28. public static final String DISP_Y="DISP_Y";
  29. public static final String DISP_Z="DISP_Z";
  30. public static final String FUNCTION="Function";
  31.  
  32. //TODO [IMPROVE] Developing relative way file localizer.
  33. //public static final String CONFIGFILELOCATION="C:\\ProjetosWS\\sifem\\bkpOne\\swapfiles\\ConceptualModel\\";
  34.  
  35. }
  36.  
  37. }
  38. ===================================================================================================================
  39. Util.java
  40. ======================
  41. #
  42. package eu.sifem.utils;
  43.  
  44. import java.io.File;
  45. import java.lang.annotation.Annotation;
  46. import java.lang.reflect.Field;
  47. import java.lang.reflect.InvocationTargetException;
  48. import java.lang.reflect.Method;
  49. import java.util.ArrayList;
  50. import java.util.Collections;
  51. import java.util.LinkedHashMap;
  52. import java.util.LinkedList;
  53. import java.util.List;
  54. import java.util.Map;
  55. import java.util.Set;
  56. import java.util.TreeMap;
  57. import java.util.TreeSet;
  58. import java.util.Map.Entry;
  59.  
  60. import javax.crypto.Cipher;
  61. import javax.crypto.SecretKey;
  62. import javax.crypto.spec.SecretKeySpec;
  63.  
  64. import org.apache.commons.codec.binary.Base64;
  65. import org.apache.commons.lang.StringUtils;
  66.  
  67. import virtuoso.jena.driver.VirtDataset;
  68. import virtuoso.jena.driver.VirtGraph;
  69. import virtuoso.jena.driver.VirtuosoQueryExecution;
  70. import virtuoso.jena.driver.VirtuosoQueryExecutionFactory;
  71.  
  72. import com.google.gson.Gson;
  73. import com.google.gson.GsonBuilder;
  74. import com.google.gson.annotations.Expose;
  75. import com.google.gson.annotations.SerializedName;
  76. import com.hp.hpl.jena.query.ResultSet;
  77. import com.hp.hpl.jena.rdf.model.RDFNode;
  78.  
  79. import eu.sifem.model.helper.MessengerCollectorHelper;
  80. import eu.sifem.model.to.DataSetHashCacheTO;
  81. import eu.sifem.model.to.ParamBean;
  82.  
  83.  
  84. /**
  85. *
  86. * @author kartik/jbjares
  87. *
  88. */
  89. public class Util {
  90.  
  91. static final String EMPTY_STRING = "";
  92. static final String Y = "y";
  93. static final String X = "x";
  94. static final String FILE = "file:///";
  95. static final String JAVA_UTIL_ARRAY_LIST = "java.util.ArrayList";
  96. static final String HTTP_WWW_SIFEMONTOLOGIES_COM_ONTOLOGIES = "http://www.sifemontologies.com/ontologies";
  97.  
  98. //TODO Refactoring is necessary, python.exe path must be transparent.
  99. static final String C_PYTHON34_PYTHON_EXE = "C:\\ProgramFilesDevel\\python\\Python34\\python.exe ";
  100. static final String DISTINCT = "DISTINCT";
  101. static final String WHERE = "WHERE";
  102. static final String SELECT = "SELECT";
  103. static final String GRAPH = "graph";
  104.  
  105. public static ParamBean getPakBean(List<ParamBean> lstOfBeans, String param) {
  106. ParamBean paramBeanTemp = new ParamBean();
  107. String paramName = null;
  108. if (param.equals(Constant.PAKSolver.DIV_L)) {
  109. paramName = Constant.PAKSolver.DIV_L;
  110. } else if (param.equals(Constant.PAKSolver.DIV_B)) {
  111. paramName = Constant.PAKSolver.DIV_B;
  112. } else if (param.equals(Constant.PAKSolver.DIV_W)) {
  113. paramName = Constant.PAKSolver.DIV_W;
  114. } else if (param.equals(Constant.PAKSolver.DIV_H)) {
  115. paramName = Constant.PAKSolver.DIV_H;
  116. } else if (param.equals(Constant.PAKSolver.DIV_h)) {
  117. paramName = Constant.PAKSolver.DIV_h;
  118. } else if (param.equals(Constant.PAKSolver.LENGTH)) {
  119. paramName = Constant.PAKSolver.LENGTH;
  120. } else if (param.equals(Constant.PAKSolver.HEIGHT)) {
  121. paramName = Constant.PAKSolver.HEIGHT;
  122. } else if (param.equals(Constant.PAKSolver.WIDTH)) {
  123. paramName = Constant.PAKSolver.WIDTH;
  124. } else if (param.equals(Constant.PAKSolver.WIDTH_OF_BM)) {
  125. paramName = Constant.PAKSolver.WIDTH_OF_BM;
  126. } else if (param.equals(Constant.PAKSolver.THICKNESS)) {
  127. paramName = Constant.PAKSolver.THICKNESS;
  128. } else if (param.equals(Constant.PAKSolver.LOAD_FREQUENCY)) {
  129. paramName = Constant.PAKSolver.LOAD_FREQUENCY;
  130. } else if (param.equals(Constant.PAKSolver.LOAD_VALUE)) {
  131. paramName = Constant.PAKSolver.LOAD_VALUE;
  132. } else if (param.equals(Constant.PAKSolver.DENSITY_RHO)) {
  133. paramName = Constant.PAKSolver.DENSITY_RHO;
  134. } else if (param.equals(Constant.PAKSolver.SPEED_OF_SOUND_C)) {
  135. paramName = Constant.PAKSolver.SPEED_OF_SOUND_C;
  136. } else if (param.equals(Constant.PAKSolver.YOUNG_MODULUS)) {
  137. paramName = Constant.PAKSolver.YOUNG_MODULUS;
  138. } else if (param.equals(Constant.PAKSolver.DAMPING)) {
  139. paramName = Constant.PAKSolver.DAMPING;
  140. } else if (param.equals(Constant.PAKSolver.DISP_X)) {
  141. paramName = Constant.PAKSolver.DISP_X;
  142. } else if (param.equals(Constant.PAKSolver.DISP_Y)) {
  143. paramName = Constant.PAKSolver.DISP_Y;
  144. } else if (param.equals(Constant.PAKSolver.DISP_Z)) {
  145. paramName = Constant.PAKSolver.DISP_Z;
  146. } else if (param.equals(Constant.PAKSolver.FUNCTION)) {
  147. paramName = Constant.PAKSolver.FUNCTION;
  148. }
  149. for (ParamBean paramBean : lstOfBeans) {
  150. if (paramBean.getPramaName().equals(paramName)) {
  151. paramBeanTemp = paramBean;
  152. break;
  153. }
  154. }
  155. return paramBeanTemp;
  156. }
  157.  
  158. public static boolean isIntegerParseInt(String str) {
  159. try {
  160. Integer.parseInt(str);
  161. return true;
  162. } catch (NumberFormatException nfe) {
  163. }
  164. return false;
  165. }
  166.  
  167.  
  168. public static String shuffleString(String str) {
  169. ArrayList<Character> chars = new ArrayList<Character>(str.length());
  170. for (char c : str.toCharArray()) {
  171. chars.add(c);
  172. }
  173. Collections.shuffle(chars);
  174. char[] shuffled = new char[chars.size()];
  175. for (int i = 0; i < shuffled.length; i++) {
  176. shuffled[i] = chars.get(i);
  177. }
  178. String shuffledWord = new String(shuffled);
  179. return shuffledWord;
  180. }
  181.  
  182. public static Map<String, String> getMappedObjectWithJustStringsAttributes(Object obj) throws Exception {
  183. Map<String, String> mappedObject = new TreeMap<String, String>();
  184. Field[] fields = obj.getClass().getDeclaredFields();
  185. Method[] methods = obj.getClass().getDeclaredMethods();
  186. for (Field field : fields) {
  187. for (Method method : methods) {
  188. if (method.getName().trim().toUpperCase()
  189. .contains(field.getName().trim().toUpperCase())
  190. && method.getName().startsWith("get")) {
  191. mappedObject.put(field.getName(),
  192. (String) method.invoke(obj));
  193. }
  194. }
  195. }
  196. return mappedObject;
  197. }
  198.  
  199.  
  200.  
  201.  
  202. public String getMappedObjectAsAtring(Map<String, String> propsWithValues) throws Exception {
  203. StringBuilder sb = new StringBuilder();
  204. for (Map.Entry<String, String> item : propsWithValues.entrySet()) {
  205. String key = item.getKey();
  206. String value = item.getValue();
  207. sb.append(key);
  208. sb.append(value);
  209. }
  210. return sb.toString();
  211. }
  212.  
  213. private static byte[] linebreak = {}; // Remove Base64 encoder default
  214. // linebreak
  215. private static String secret = "tvnw63ufg9gh5392"; // secret key length must
  216. // be 16
  217. private static SecretKey key;
  218. private static Cipher cipher;
  219. private static Base64 coder;
  220.  
  221.  
  222. public static String encryptAES(String plainText)
  223. throws Exception {
  224. key = new SecretKeySpec(secret.getBytes(), "MD5");
  225. cipher = Cipher.getInstance("AES/ECB/PKCS5Padding", "SunJCE");
  226. coder = new Base64(32, linebreak, true);
  227. cipher.init(Cipher.ENCRYPT_MODE, key);
  228. byte[] cipherText = cipher.doFinal(plainText.getBytes());
  229. return new String(coder.encode(cipherText));
  230. }
  231.  
  232. public static byte[] encryptBase64(String plainText)
  233. throws Exception {
  234. byte[] bytesEncoded = Base64.encodeBase64(plainText.getBytes());
  235. return bytesEncoded;
  236. }
  237.  
  238. public static byte[] dencryptBase64(String plainText)
  239. throws Exception {
  240. byte[] valueDecoded= Base64.decodeBase64(plainText);
  241. return valueDecoded;
  242. }
  243.  
  244.  
  245.  
  246. public static String generateHashCacheID(DataSetHashCacheTO cache) throws Exception{
  247. String projectName = cache.getProjectName()==null?"":cache.getProjectName();
  248. String simulationName = cache.getSimulationName()==null?"":cache.getSimulationName();
  249. String xName = cache.getxName()==null?"":cache.getxName();
  250. String yName = cache.getyName()==null?"":cache.getyName();
  251. String zName = cache.getzName()==null?"":cache.getzName();
  252. String result = projectName+"_"+simulationName+"_"+xName+"_"+yName+"_"+zName;
  253. return result.toUpperCase();
  254. }
  255.  
  256. public String toProperCase(String s) {
  257. String temp=s.trim();
  258. String spaces="";
  259. if(temp.length()!=s.length())
  260. {
  261. int startCharIndex=s.charAt(temp.indexOf(0));
  262. spaces=s.substring(0,startCharIndex);
  263. }
  264. temp=temp.substring(0, 1).toUpperCase() +
  265. spaces+temp.substring(1).toLowerCase()+" ";
  266. return temp;
  267.  
  268. }
  269.  
  270. public String replaceSpacesForUnderline(String in){
  271. if(in==null || "".equals(in)){
  272. return in;
  273. }
  274.  
  275. while(in.contains(" ")){
  276. in = in.replace(" ","_");
  277. }
  278. return in;
  279. }
  280.  
  281. public String replaceUnderlinesForSpace(String in){
  282. if(in==null || "".equals(in)){
  283. return in;
  284. }
  285.  
  286. while(in.contains("_")){
  287. in = in.replace("_"," ");
  288. }
  289. return in;
  290. }
  291.  
  292. public String removeSpecialIdentationCharsFromString(String str){
  293. return str.replaceAll("[\n\r\t]", " ");
  294. }
  295.  
  296. public void createDirectoriesWithMkdirsIfItNotExist(File file){
  297. if(!file.exists()){
  298. file.mkdirs();
  299. }else{
  300. file.delete();
  301. file.mkdirs();
  302. }
  303. }
  304.  
  305. public static String changeStringToDefaultSeparator(String parameterValuesFromFile) {
  306.  
  307. parameterValuesFromFile = StringUtils.deleteWhitespace(parameterValuesFromFile);
  308. if(StringUtils.containsIgnoreCase(parameterValuesFromFile,";")){
  309. return parameterValuesFromFile;
  310. }
  311. if(StringUtils.containsIgnoreCase(parameterValuesFromFile,"\n") && !StringUtils.containsIgnoreCase(parameterValuesFromFile,";")){
  312. parameterValuesFromFile = StringUtils.replace(parameterValuesFromFile,"\n", ";");
  313. return parameterValuesFromFile;
  314. }
  315. if(StringUtils.containsIgnoreCase(parameterValuesFromFile,",") && !StringUtils.containsIgnoreCase(parameterValuesFromFile,";")){
  316. parameterValuesFromFile = StringUtils.replace(parameterValuesFromFile,",", ";");
  317. return parameterValuesFromFile;
  318. }
  319. if(StringUtils.containsIgnoreCase(parameterValuesFromFile,System.getProperty("file.separator")) && !StringUtils.containsIgnoreCase(parameterValuesFromFile,";")){
  320. parameterValuesFromFile = StringUtils.replace(parameterValuesFromFile, System.getProperty("file.separator"), ";");
  321. return parameterValuesFromFile;
  322. }
  323.  
  324. return parameterValuesFromFile;
  325. }
  326.  
  327. public static int countPossiblesCombinationsBetweenMapKeysAndValues(Map<String, List<String>> mapAttributeValues) {
  328. int values = 0;
  329. for (Map.Entry<String,List<String>> entry : mapAttributeValues.entrySet()) {
  330. values = values + entry.getValue().size();
  331. }
  332. return mapAttributeValues.size()*values;
  333. }
  334.  
  335. public static void main(String[] args) {
  336. Map<String, List<String>> mapAttributeValues = new TreeMap<String, List<String>>();
  337.  
  338. for(int i = 0; i< 3; i ++){
  339. List<String> valueList = new ArrayList<String>();
  340. for(int j = 0; j< 3; j ++){
  341. valueList.add(new Integer(j).toString());
  342. //System.out.println(j);
  343. System.out.println(j);
  344. }
  345. mapAttributeValues.put(new Integer(i).toString(),valueList);
  346. }
  347. System.out.println(mapAttributeValues.size());
  348.  
  349.  
  350. System.out.println(countPossiblesCombinationsBetweenMapKeysAndValues(mapAttributeValues));
  351. // System.out.println(Util.tryCleanToNumeric("^&%^&%$%^-100.00,00"));
  352. }
  353.  
  354. public static String tryCleanToNumeric(String value) {
  355. StringBuilder sb = new StringBuilder();
  356. char[] charArr = value.toCharArray();
  357. for(Character realChar:charArr){
  358. String charStr = realChar.toString();
  359. if(".".equals(charStr)){
  360. sb.append(charStr);
  361. }
  362. if(",".equals(charStr)){
  363. sb.append(charStr);
  364. }
  365. if("-".equals(charStr)){
  366. sb.append(charStr);
  367. }
  368. if(StringUtils.isNumeric(charStr)){
  369. sb.append(charStr);
  370. }
  371. }
  372. return sb.toString();
  373. }
  374.  
  375. public static String removeListKeysFromString(String arg){
  376. if(arg==null || "".equals(arg)){
  377. return arg;
  378. }
  379. arg = StringUtils.replaceChars(arg,"[","");
  380. arg = StringUtils.replaceChars(arg,"]","");
  381. return arg;
  382. }
  383.  
  384. public static String getJsonStrFromObject(Object obj) {
  385. Gson gson = new GsonBuilder().create();
  386. return gson.toJson(obj);
  387. }
  388.  
  389. public static ResultSet executeQuery(String query, VirtDataset virtDataset) {
  390. VirtGraph vg = new VirtGraph(virtDataset.getGraphUrl(),
  391. virtDataset.getGraphUser(), virtDataset.getGraphPassword());
  392. VirtuosoQueryExecution vur = VirtuosoQueryExecutionFactory.create(
  393. query, vg);
  394. ResultSet rs = vur.execSelect();
  395. return rs;
  396. }
  397.  
  398.  
  399.  
  400.  
  401. // format values
  402. public Map<String, List<String>> getValues(Map<String, List<RDFNode>> queryModel, String queryStr) throws Exception {
  403. Map<String, List<String>> result = new LinkedHashMap<String, List<String>>();
  404.  
  405. Map<String, String> queryAttributes = new LinkedHashMap<String, String>();
  406. Set<String> checkAttributes = new TreeSet<String>();
  407. fillQueryAttributes(queryStr, queryAttributes);
  408.  
  409. Set<String> usedKeys = new TreeSet<String>();
  410. List<RDFNode> usedResources = new ArrayList<RDFNode>();
  411.  
  412. for (Map.Entry<String, String> entry : queryAttributes.entrySet()) {
  413.  
  414. for (Map.Entry entryQueryModel : queryModel.entrySet()) {
  415. if (usedKeys.contains(entryQueryModel.getKey())) {
  416. continue;
  417. }
  418. String mainkey = (String) entryQueryModel.getKey();
  419. usedKeys.add(mainkey);
  420.  
  421. if (JAVA_UTIL_ARRAY_LIST.equals(entryQueryModel.getValue()
  422. .getClass().getName())) {
  423. @SuppressWarnings("unchecked")
  424. List<RDFNode> rdfnodeList = (List<RDFNode>) entryQueryModel
  425. .getValue();
  426.  
  427. List pyList = new ArrayList(new ArrayList<String>());
  428. int count = 0;
  429. for (RDFNode node : rdfnodeList) {
  430. if (node.isLiteral()) {
  431. String literalNodeAsString = node.asLiteral()
  432. .toString();
  433. literalNodeAsString = literalNodeAsString
  434. .substring(0,
  435. literalNodeAsString.indexOf("^^"));
  436. pyList.add("'" + literalNodeAsString + "'");
  437. count++;
  438. }
  439. if (node.isResource()) {
  440. if (!usedResources
  441. .toString()
  442. .toString()
  443. .contains(
  444. node.asResource().toString()
  445. .toString())) {
  446. usedResources.add(node);
  447. }
  448.  
  449. if (!node
  450. .asResource()
  451. .getURI()
  452. .contains(
  453. HTTP_WWW_SIFEMONTOLOGIES_COM_ONTOLOGIES)) {
  454. continue;
  455. }
  456. pyList.add("'" + node.asResource().getURI() + "'");
  457. count++;
  458. }
  459. int rdfnodeListSize = rdfnodeList.size();
  460.  
  461. if (rdfnodeListSize == count) {
  462. String key = (String) entryQueryModel.getKey();
  463. result.put(new String(key), pyList);
  464. checkAttributes.add(key);
  465. count = 0;
  466. continue;
  467. }
  468.  
  469. }
  470.  
  471. }
  472.  
  473. }
  474.  
  475. }
  476.  
  477. return result;
  478.  
  479. }
  480.  
  481.  
  482.  
  483. public void fillQueryAttributes(String originalQuery,
  484. Map<String, String> attributes) throws Exception {
  485. String query = BasicFileTools
  486. .verifyAndConvertFileToString(originalQuery);
  487. if (query == null || "".equals(query)) {
  488. throw new RuntimeException("Empty or invalid query!");
  489. }
  490.  
  491. if (!query.trim().toUpperCase().contains(SELECT.trim().toUpperCase())
  492. && !query.trim().toUpperCase()
  493. .contains(WHERE.trim().toUpperCase())) {
  494. return;
  495. }
  496.  
  497. Boolean thisQueryContainsWehereClause = StringUtils.containsIgnoreCase(
  498. query, WHERE);
  499. if (thisQueryContainsWehereClause) {
  500. query = query.trim().substring(
  501. StringUtils.indexOfIgnoreCase(query, SELECT)
  502. + SELECT.length(),
  503. StringUtils.indexOfIgnoreCase(query, WHERE));
  504. }
  505.  
  506. Boolean thisQueryContainsGraphClause = StringUtils.containsIgnoreCase(
  507. query, GRAPH);
  508. if (thisQueryContainsGraphClause) {
  509. query = query.trim().substring(
  510. StringUtils.indexOfIgnoreCase(query, SELECT)
  511. + SELECT.length(),
  512. StringUtils.indexOfIgnoreCase(query, GRAPH));
  513. }
  514.  
  515. if (StringUtils.startsWithIgnoreCase(query, DISTINCT)) {
  516. StringUtils.removeStartIgnoreCase(query, DISTINCT);
  517. }
  518. if (!query.trim().startsWith("?")) {
  519. throw new RuntimeException(
  520. "Malformed SPARQL Query. This version assumes that all query is followed by attributes (starting with ?). ");
  521. }
  522. query = query.substring(1, query.length());
  523. if (query.contains("?")) {
  524. query = query.replace("?", ";").trim();
  525. String[] attributesArr = query.split(";");
  526. for (String attribute : attributesArr) {
  527. if ("".equals(attribute)) {
  528. continue;
  529. }
  530. if (attribute.trim().contains("{")) {
  531. attribute = StringUtils.remove(attribute, "{");
  532. }
  533. attributes.put(attribute.trim(), attribute.trim());
  534. }
  535. return;
  536. }
  537. String uniqueAttribute = query;
  538. attributes.put(uniqueAttribute, uniqueAttribute);
  539. return;
  540. }
  541.  
  542. public List<String> removeDuplicatedValues(List<String> original){
  543. List<String> finalList = new ArrayList<String>();
  544.  
  545. for (String s : original) {
  546. if (!finalList.contains(s)) {
  547. finalList.add(s);
  548. }
  549. }
  550. return finalList;
  551. }
  552.  
  553. }
  554.  
  555. ===================================================================================================================
  556. input.cfg
  557. ======================
  558. #
  559. #MESH DIVISIONS
  560. #(UINT)DIV_L (UINT)DIV_W (UINT)DIV_B (UINT)DIV_H (UINT)DIV_h
  561. 100 4 4 4 3
  562.  
  563. #GEOMETRY PARAMETERS
  564. #(DOUBLE)LENGTH (DOUBLE)HEIGHT (DOUBLE)WIDTH (DOUBLE)WIDTH_OF_BM (DOUBLE)THICKNESS
  565. 3.5e-02 1.0e-03 1.0e-03 3.0e-04 5.0e-05
  566.  
  567. #LOAD PARAMETERS
  568. #(DOUBLE)FREQUENCY (DOUBLE)VALUE
  569. 1000.0 1.0
  570.  
  571. #MATERIAL PROPERTIES
  572. #(DOUBLE)DENSITY_RHO (DOUBLE)SPEED_OF_SOUND_C
  573. 1000 1500
  574.  
  575. #YOUNG MODULUS FUNCTION
  576. #(DOUBLE)X_AXIS (DOUBLE)Y_AXIS
  577. 0.00 14101716.45
  578. 0.01 12759760.71
  579. 0.02 11545508.93
  580. 0.03 10446808.49
  581. 0.04 9452663.223
  582. 0.05 8553123.384
  583. 0.06 7739186.079
  584. 0.07 7002705.15
  585. 0.08 6336309.647
  586. 0.09 5733330.061
  587. 0.10 5187731.569
  588. 0.11 4694053.638
  589. 0.12 4247355.374
  590. 0.13 3843166.07
  591. 0.14 3477440.464
  592. 0.15 3146518.251
  593. 0.16 2847087.45
  594. 0.17 2576151.257
  595. 0.18 2330998.052
  596. 0.19 2109174.259
  597. 0.20 1908459.791
  598. 0.21 1726845.829
  599. 0.22 1562514.722
  600. 0.23 1413821.786
  601. 0.24 1279278.855
  602. 0.25 1157539.376
  603. 0.26 1047384.94
  604. 0.27 947713.0849
  605. 0.28 857526.2607
  606. 0.29 775921.8477
  607. 0.30 702083.1212
  608. 0.31 635271.0787
  609. 0.32 574817.0426
  610. 0.33 520115.9687
  611. 0.34 470620.3902
  612. 0.35 425834.9387
  613. 0.36 385311.3864
  614. 0.37 348644.16
  615. 0.38 315466.2816
  616. 0.39 285445.6957
  617. 0.40 258281.9463
  618. 0.41 233703.1694
  619. 0.42 211463.3724
  620. 0.43 191339.9719
  621. 0.44 173131.5661
  622. 0.45 156655.9193
  623. 0.46 141748.1375
  624. 0.47 128259.0188
  625. 0.48 116053.5594
  626. 0.49 105009.603
  627. 0.50 95016.61807
  628. 0.51 85974.59136
  629. 0.52 77793.02727
  630. 0.53 70390.04193
  631. 0.54 63691.5438
  632. 0.55 57630.49204
  633. 0.56 52146.22562
  634. 0.57 47183.85615
  635. 0.58 42693.71857
  636. 0.59 38630.87408
  637. 0.60 34954.66036
  638. 0.61 31628.28463
  639. 0.62 28618.4554
  640. 0.63 25895.04929
  641. 0.64 23430.80954
  642. 0.65 21201.07321
  643. 0.66 19183.52434
  644. 0.67 17357.97063
  645. 0.68 15706.14133
  646. 0.69 14211.50437
  647. 0.70 12859.10092
  648. 0.71 11635.39567
  649. 0.72 10528.14138
  650. 0.73 9526.256262
  651. 0.74 8619.71312
  652. 0.75 7799.438963
  653. 0.76 7057.224214
  654. 0.77 6385.640536
  655. 0.78 5777.966495
  656. 0.79 5228.120285
  657. 0.80 4730.59886
  658. 0.81 4280.422858
  659. 0.82 3873.086767
  660. 0.83 3504.51383
  661. 0.84 3171.015246
  662. 0.85 2869.253247
  663. 0.86 2596.2077
  664. 0.87 2349.145872
  665. 0.88 2125.595085
  666. 0.89 1923.317969
  667. 0.90 1740.290065
  668. 0.91 1574.679569
  669. 0.92 1424.828995
  670. 0.93 1289.238589
  671. 0.94 1166.551316
  672. 0.95 1055.539281
  673. 0.96 955.091438
  674. 0.97 864.202471
  675. 0.98 781.962732
  676. 0.99 707.54914
  677. 1.00 640.216937
  678.  
  679. #DAMPING FUNCTION
  680. #(DOUBLE)X_AXIS (DOUBLE)Y_AXIS
  681. 0.00 0.01
  682. 0.01 0.010513
  683. 0.02 0.011052
  684. 0.03 0.011618
  685. 0.04 0.012214
  686. 0.05 0.01284
  687. 0.06 0.013499
  688. 0.07 0.014191
  689. 0.08 0.014918
  690. 0.09 0.015683
  691. 0.10 0.016487
  692. 0.11 0.017333
  693. 0.12 0.018221
  694. 0.13 0.019155
  695. 0.14 0.020138
  696. 0.15 0.02117
  697. 0.16 0.022255
  698. 0.17 0.023396
  699. 0.18 0.024596
  700. 0.19 0.025857
  701. 0.20 0.027183
  702. 0.21 0.028577
  703. 0.22 0.030042
  704. 0.23 0.031582
  705. 0.24 0.033201
  706. 0.25 0.034903
  707. 0.26 0.036693
  708. 0.27 0.038574
  709. 0.28 0.040552
  710. 0.29 0.042631
  711. 0.30 0.044817
  712. 0.31 0.047115
  713. 0.32 0.04953
  714. 0.33 0.05207
  715. 0.34 0.054739
  716. 0.35 0.057546
  717. 0.36 0.060496
  718. 0.37 0.063598
  719. 0.38 0.066859
  720. 0.39 0.070287
  721. 0.40 0.073891
  722. 0.41 0.077679
  723. 0.42 0.081662
  724. 0.43 0.085849
  725. 0.44 0.09025
  726. 0.45 0.094877
  727. 0.46 0.099742
  728. 0.47 0.104856
  729. 0.48 0.110232
  730. 0.49 0.115883
  731. 0.50 0.121825
  732. 0.51 0.128071
  733. 0.52 0.134637
  734. 0.53 0.14154
  735. 0.54 0.148797
  736. 0.55 0.156426
  737. 0.56 0.164446
  738. 0.57 0.172878
  739. 0.58 0.181741
  740. 0.59 0.19106
  741. 0.60 0.200855
  742. 0.61 0.211153
  743. 0.62 0.22198
  744. 0.63 0.233361
  745. 0.64 0.245325
  746. 0.65 0.257903
  747. 0.66 0.271126
  748. 0.67 0.285027
  749. 0.68 0.299641
  750. 0.69 0.315004
  751. 0.70 0.331155
  752. 0.71 0.348133
  753. 0.72 0.365982
  754. 0.73 0.384747
  755. 0.74 0.404473
  756. 0.75 0.425211
  757. 0.76 0.447012
  758. 0.77 0.469931
  759. 0.78 0.494024
  760. 0.79 0.519354
  761. 0.80 0.545982
  762. 0.81 0.573975
  763. 0.82 0.603403
  764. 0.83 0.63434
  765. 0.84 0.666863
  766. 0.85 0.701054
  767. 0.86 0.736998
  768. 0.87 0.774785
  769. 0.88 0.814509
  770. 0.89 0.856269
  771. 0.90 0.900171
  772. 0.91 0.946324
  773. 0.92 0.994843
  774. 0.93 1.04585
  775. 0.94 1.099472
  776. 0.95 1.155843
  777. 0.96 1.215104
  778. 0.97 1.277404
  779. 0.98 1.342898
  780. 0.99 1.41175
  781. 1.00 1.484132
  782.  
  783. #EXTERNAL LOAD PARAMETERS
  784. #(DOUBLE)DISP_X (DOUBLE)DISP_Y (DOUBLE)DISP_Z
  785. 0.0 0.0 0.0
  786.  
  787. #FUNCTION
  788. #(DOUBLE)X_AXIS (DOUBLE)Y_AXIS
  789. 0 0
  790. 0.00002 0.125333
  791. 0.00004 0.24869
  792. 0.00006 0.368125
  793. 0.00008 0.481754
  794. 0.0001 0.587785
  795. 0.00012 0.684547
  796. 0.00014 0.770513
  797. 0.00016 0.844328
  798. 0.00018 0.904827
  799. 0.0002 0.951057
  800. 0.00022 0.982287
  801. 0.00024 0.998027
  802. 0.00026 0.998027
  803. 0.00028 0.982287
  804. 0.0003 0.951057
  805. 0.00032 0.904827
  806. 0.00034 0.844328
  807. 0.00036 0.770513
  808. 0.00038 0.684547
  809. 0.0004 0.587785
  810. 0.00042 0.481754
  811. 0.00044 0.368125
  812. 0.00046 0.24869
  813. 0.00048 0.125333
  814. 0.0005 0
  815. 0.00052 -0.125333
  816. 0.00054 -0.24869
  817. 0.00056 -0.368125
  818. 0.00058 -0.481754
  819. 0.0006 -0.587785
  820. 0.00062 -0.684547
  821. 0.00064 -0.770513
  822. 0.00066 -0.844328
  823. 0.00068 -0.904827
  824. 0.0007 -0.951057
  825. 0.00072 -0.982287
  826. 0.00074 -0.998027
  827. 0.00076 -0.998027
  828. 0.00078 -0.982287
  829. 0.0008 -0.951057
  830. 0.00082 -0.904827
  831. 0.00084 -0.844328
  832. 0.00086 -0.770513
  833. 0.00088 -0.684547
  834. 0.0009 -0.587785
  835. 0.00092 -0.481754
  836. 0.00094 -0.368125
  837. 0.00096 -0.24869
  838. 0.00098 -0.125333
  839. 0.001 0
  840. 0.001 0
  841. 0.00102 0.125333
  842. 0.00104 0.24869
  843. 0.00106 0.368125
  844. 0.00108 0.481754
  845. 0.0011 0.587785
  846. 0.00112 0.684547
  847. 0.00114 0.770513
  848. 0.00116 0.844328
  849. 0.00118 0.904827
  850. 0.0012 0.951057
  851. 0.00122 0.982287
  852. 0.00124 0.998027
  853. 0.00126 0.998027
  854. 0.00128 0.982287
  855. 0.0013 0.951057
  856. 0.00132 0.904827
  857. 0.00134 0.844328
  858. 0.00136 0.770513
  859. 0.00138 0.684547
  860. 0.0014 0.587785
  861. 0.00142 0.481754
  862. 0.00144 0.368125
  863. 0.00146 0.24869
  864. 0.00148 0.125333
  865. 0.0015 0
  866. 0.00152 -0.125333
  867. 0.00154 -0.24869
  868. 0.00156 -0.368125
  869. 0.00158 -0.481754
  870. 0.0016 -0.587785
  871. 0.00162 -0.684547
  872. 0.00164 -0.770513
  873. 0.00166 -0.844328
  874. 0.00168 -0.904827
  875. 0.0017 -0.951057
  876. 0.00172 -0.982287
  877. 0.00174 -0.998027
  878. 0.00176 -0.998027
  879. 0.00178 -0.982287
  880. 0.0018 -0.951057
  881. 0.00182 -0.904827
  882. 0.00184 -0.844328
  883. 0.00186 -0.770513
  884. 0.00188 -0.684547
  885. 0.0019 -0.587785
  886. 0.00192 -0.481754
  887. 0.00194 -0.368125
  888. 0.00196 -0.24869
  889. 0.00198 -0.125333
  890. 0.002 0
  891. 0.002 0
  892. 0.00202 0.125333
  893. 0.00204 0.24869
  894. 0.00206 0.368125
  895. 0.00208 0.481754
  896. 0.0021 0.587785
  897. 0.00212 0.684547
  898. 0.00214 0.770513
  899. 0.00216 0.844328
  900. 0.00218 0.904827
  901. 0.0022 0.951057
  902. 0.00222 0.982287
  903. 0.00224 0.998027
  904. 0.00226 0.998027
  905. 0.00228 0.982287
  906. 0.0023 0.951057
  907. 0.00232 0.904827
  908. 0.00234 0.844328
  909. 0.00236 0.770513
  910. 0.00238 0.684547
  911. 0.0024 0.587785
  912. 0.00242 0.481754
  913. 0.00244 0.368125
  914. 0.00246 0.24869
  915. 0.00248 0.125333
  916. 0.0025 0
  917. 0.00252 -0.125333
  918. 0.00254 -0.24869
  919. 0.00256 -0.368125
  920. 0.00258 -0.481754
  921. 0.0026 -0.587785
  922. 0.00262 -0.684547
  923. 0.00264 -0.770513
  924. 0.00266 -0.844328
  925. 0.00268 -0.904827
  926. 0.0027 -0.951057
  927. 0.00272 -0.982287
  928. 0.00274 -0.998027
  929. 0.00276 -0.998027
  930. 0.00278 -0.982287
  931. 0.0028 -0.951057
  932. 0.00282 -0.904827
  933. 0.00284 -0.844328
  934. 0.00286 -0.770513
  935. 0.00288 -0.684547
  936. 0.0029 -0.587785
  937. 0.00292 -0.481754
  938. 0.00294 -0.368125
  939. 0.00296 -0.24869
  940. 0.00298 -0.125333
  941. 0.003 0
  942. 0.003 0
  943. 0.00302 0.125333
  944. 0.00304 0.24869
  945. 0.00306 0.368125
  946. 0.00308 0.481754
  947. 0.0031 0.587785
  948. 0.00312 0.684547
  949. 0.00314 0.770513
  950. 0.00316 0.844328
  951. 0.00318 0.904827
  952. 0.0032 0.951057
  953. 0.00322 0.982287
  954. 0.00324 0.998027
  955. 0.00326 0.998027
  956. 0.00328 0.982287
  957. 0.0033 0.951057
  958. 0.00332 0.904827
  959. 0.00334 0.844328
  960. 0.00336 0.770513
  961. 0.00338 0.684547
  962. 0.0034 0.587785
  963. 0.00342 0.481754
  964. 0.00344 0.368125
  965. 0.00346 0.24869
  966. 0.00348 0.125333
  967. 0.0035 0
  968. 0.00352 -0.125333
  969. 0.00354 -0.24869
  970. 0.00356 -0.368125
  971. 0.00358 -0.481754
  972. 0.0036 -0.587785
  973. 0.00362 -0.684547
  974. 0.00364 -0.770513
  975. 0.00366 -0.844328
  976. 0.00368 -0.904827
  977. 0.0037 -0.951057
  978. 0.00372 -0.982287
  979. 0.00374 -0.998027
  980. 0.00376 -0.998027
  981. 0.00378 -0.982287
  982. 0.0038 -0.951057
  983. 0.00382 -0.904827
  984. 0.00384 -0.844328
  985. 0.00386 -0.770513
  986. 0.00388 -0.684547
  987. 0.0039 -0.587785
  988. 0.00392 -0.481754
  989. 0.00394 -0.368125
  990. 0.00396 -0.24869
  991. 0.00398 -0.125333
  992. 0.004 0
  993. 0.004 0
  994. 0.00402 0.125333
  995. 0.00404 0.24869
  996. 0.00406 0.368125
  997. 0.00408 0.481754
  998. 0.0041 0.587785
  999. 0.00412 0.684547
  1000. 0.00414 0.770513
  1001. 0.00416 0.844328
  1002. 0.00418 0.904827
  1003. 0.0042 0.951057
  1004. 0.00422 0.982287
  1005. 0.00424 0.998027
  1006. 0.00426 0.998027
  1007. 0.00428 0.982287
  1008. 0.0043 0.951057
  1009. 0.00432 0.904827
  1010. 0.00434 0.844328
  1011. 0.00436 0.770513
  1012. 0.00438 0.684547
  1013. 0.0044 0.587785
  1014. 0.00442 0.481754
  1015. 0.00444 0.368125
  1016. 0.00446 0.24869
  1017. 0.00448 0.125333
  1018. 0.0045 0
  1019. 0.00452 -0.125333
  1020. 0.00454 -0.24869
  1021. 0.00456 -0.368125
  1022. 0.00458 -0.481754
  1023. 0.0046 -0.587785
  1024. 0.00462 -0.684547
  1025. 0.00464 -0.770513
  1026. 0.00466 -0.844328
  1027. 0.00468 -0.904827
  1028. 0.0047 -0.951057
  1029. 0.00472 -0.982287
  1030. 0.00474 -0.998027
  1031. 0.00476 -0.998027
  1032. 0.00478 -0.982287
  1033. 0.0048 -0.951057
  1034. 0.00482 -0.904827
  1035. 0.00484 -0.844328
  1036. 0.00486 -0.770513
  1037. 0.00488 -0.684547
  1038. 0.0049 -0.587785
  1039. 0.00492 -0.481754
  1040. 0.00494 -0.368125
  1041. 0.00496 -0.24869
  1042. 0.00498 -0.125333
  1043. 0.005 0
  1044. 0.00502 0
Add Comment
Please, Sign In to add comment