private bool TryReadCtrlPtsParDef(CaratReader reader) { if (!reader.Match("CTRL_PTS_PAR_DEF")) { return(false); } // TODO: process data Console.WriteLine($"CTRL_PTS_PAR_DEF"); while (!reader.EOF) { if (!reader.Match("CTRLPT_PAR")) { break; } var id = reader.ReadInteger(); var x = reader.ReadDouble(); var y = reader.ReadDouble(); var z = reader.ReadDouble(); // TODO: process data Console.WriteLine($" CTRLPT_PAR ID {id} X {x} Y {y} Z {z}"); } return(true); }
private bool TryReadNdCoor(CaratReader reader) { if (!reader.Match("ND-COOR")) { return(false); } // TODO: process data Console.WriteLine($"ND-COOR"); while (!reader.EOF) { if (!reader.Match("NODE")) { break; } var id = reader.ReadInteger(); var x = default(double); var y = default(double); var z = default(double); while (!reader.EOF) { if (reader.Match("X")) { x = reader.ReadDouble(); continue; } if (reader.Match("Y")) { y = reader.ReadDouble(); continue; } if (reader.Match("Z")) { z = reader.ReadDouble(); continue; } break; } // TODO: process data Console.WriteLine($" NODE ID {id} X {x} Y {y} Z {z}"); } return(true); }
private bool TryReadCoupPointGeo(CaratReader reader) { if (!reader.Match("COUP_POINT_GEO")) { return(false); } var value = reader.ReadInteger(); var u = reader.ReadDouble(); var v = reader.ReadDouble(); // TODO: process data Console.WriteLine($"COUP_POINT_GEO U {u} V {v} ..."); return(true); }
private bool TryReadCtrlPtsNodes(CaratReader reader) { if (!reader.Match("CTRL_PTS_NODES")) { return(false); } var id = reader.ReadInteger(); // TODO: process data Console.WriteLine($"CTRL_PTS_NODES ID {id}"); while (!reader.EOF) { if (reader.Match("NODE_ID")) { var nodeId = reader.ReadInteger(); reader.Expect("W"); var w = reader.ReadDouble(); // TODO: process data Console.WriteLine($" NODE_ID ID {id} WEIGHT {w}"); continue; } break; } return(true); }
private bool TryReadEvalPoint(CaratReader reader) { if (!reader.Match("EVAL_POINT")) { return(false); } var value1 = reader.ReadInteger(); var value2 = reader.ReadInteger(); var u = reader.ReadDouble(); var v = reader.ReadDouble(); // TODO: process data Console.WriteLine($"EVAL_POINT U {u} V {v} ..."); return(true); }
private bool TryReadDeEleProp(CaratReader reader) { if (!reader.Match("DE_ELE_PROP")) { return(false); } var id = reader.ReadInteger(); var youngsmodulus = reader.ReadDouble(); var poisonsratio = reader.ReadDouble(); var alpha = reader.ReadDouble(); var density = reader.ReadDouble(); var type = reader.ReadString(); var thickness = reader.ReadDouble(); // TODO: process data Console.WriteLine($"DE_ELE_PROP ID {id} ..."); return(true); }