FhSim  3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
SCableSectionData.h
1#ifndef S_CABLE_SECTION_DATA_H
2#define S_CABLE_SECTION_DATA_H
3
4#include <string>
5#include <vector>
6
7#include "net/NTrawlSpec.h"
8
10{
11 double D;
12 double E;
13 double L;
14 int Conn[2];
15 double Rho;
16 std::string MaterialName;
17 double DrawScale;
18 unsigned short NumSpheres;
19 double* SphereD;
20 double* SphereMass;
21 double* SpherePos;
22 unsigned short NumDisks;
23 double* DiskD;
24 double* DiskThickness;
25 double* DiskMass;
26 double* DiskPos;
27 double AddedWeightInWater;
28 double RefineFactor;
29 std::vector<std::string> VsSphereMaterial;
30 std::vector<std::string> VsDiskMaterial;
33 {
34 bool firstHalf;
35 double pos;
36 };
37 std::vector<HalfPlacement> SphereHalves;
38 std::vector<HalfPlacement> DiskHalves;
40
44 SCableSectionData& operator=(const SCableSectionData& old);
49 void Initialize(double dL = 10.0,
50 double dD = 0.01,
51 double dRho = 1025,
52 double dE = 1e9,
53 double dRefineFactor = 1,
54 std::string sMaterialName = "Trawl/Wire2",
55 double dDrawScale = 1);
56 void AddSpheres(unsigned short iNum, double dDiameter, double dRho, double dEndPos, double dStartPos, std::string sMaterial = "floater");
57 void AddSpheres(unsigned short iNum, double dDiameter, double dRho, std::string sMaterial = "floater");
58 void AddDisks(unsigned short iNum, double dDiameter, double dThickness, double dRho, double dEndPos, double dStartPos, std::string sMaterial = "floater");
59 void AddDisks(unsigned short iNum, double dDiameter, double dThickness, double dRho, std::string sMaterial = "floater");
60 void DeleteSpheres();
61 void ResetSpheres();
62 void ResetDisks();
63
64private:
66 void AddSphereGroup(unsigned short iNum, double dDiameter, double dRho, const std::vector<double>& positions,
67 const std::vector<HalfPlacement>& halves, const std::string& sMaterial);
69 void AddDiskGroup(unsigned short iNum, double dDiameter, double dThickness, double dRho, const std::vector<double>& positions,
70 const std::vector<HalfPlacement>& halves, const std::string& sMaterial);
71};
72#endif
Where each sphere and disk goes if the line is divided into two mirror-image halves (GetHalfCable).
Definition SCableSectionData.h:33
bool firstHalf
On the first half, else on the second.
Definition SCableSectionData.h:34
double pos
Position on its half, a fraction from the half's outer end.
Definition SCableSectionData.h:35
Definition SCableSectionData.h:10
SCableSectionData GetHalfCable(bool bFirstHalf)
Definition NTrawlSpec.h:226