FhSim
3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
CSwitch.h
1
#ifndef CSwitch_H
2
#define CSwitch_H
3
62
#include <fhsim/simobject/SimObject.h>
63
64
#include <string>
65
66
class
CSwitch
:
public
SimObject
67
{
68
public
:
69
enum
SwitchType
70
{
71
PASS1_IF2_POSITIVE,
72
PASS3_IF2_POSITIVE,
73
PASS1_IF2_ZERO,
74
PASS3_IF2_ZERO
75
};
76
78
CSwitch
(std::string sSimObjectName, ISimObjectCreator* pCreator);
79
~CSwitch
();
80
virtual
void
OdeFcn(
const
double
dT,
const
double
*
const
adX,
double
*
const
adXDot)
const
{ }
81
82
const
double
* Output(
const
double
T,
const
double
*
const
X);
83
84
85
86
protected
:
87
SwitchType Type;
88
89
ISignalPort* m_Input1;
90
ISignalPort* m_Input2;
91
ISignalPort* m_Input3;
92
93
double
* m_Signal;
94
95
int
m_iPortWidth
;
96
};
97
98
99
#endif
CSwitch
Definition
CSwitch.h:67
CSwitch::m_iPortWidth
int m_iPortWidth
The width of the input and output ports.
Definition
CSwitch.h:95
CSwitch::CSwitch
CSwitch(std::string sSimObjectName, ISimObjectCreator *pCreator)
Constructor.
webfhsim
reloadrepos
fhsim_base
src
signal
CSwitch.h
Generated on Mon Oct 26 2026 12:16:38 for FhSim by
1.9.8