DPsim
Loading...
Searching...
No Matches
dpsim-models
include
dpsim-models
Solver
DAEInterface.h
1
/* Copyright 2017-2021 Institute for Automation of Complex Power Systems,
2
* EONERC, RWTH Aachen University
3
*
4
* This Source Code Form is subject to the terms of the Mozilla Public
5
* License, v. 2.0. If a copy of the MPL was not distributed with this
6
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
7
*********************************************************************************/
8
9
#pragma once
10
11
#include <dpsim-models/Definitions.h>
12
#include <vector>
13
14
namespace
CPS {
15
class
DAEInterface
{
16
public
:
17
typedef
std::shared_ptr<DAEInterface> Ptr;
18
typedef
std::vector<Ptr> List;
19
20
using
ResFn = std::function<void(
double
,
const
double
*,
const
double
*,
21
double
*, std::vector<int> &)>;
22
23
// #### DAE Section ####
25
virtual
void
daeResidual
(
double
ttime,
const
double
state[],
26
const
double
dstate_dt[],
double
resid[],
27
std::vector<int> &off) = 0;
29
virtual
Complex
daeInitialize
() = 0;
30
};
31
}
// namespace CPS
CPS::DAEInterface
Definition
DAEInterface.h:15
CPS::DAEInterface::daeResidual
virtual void daeResidual(double ttime, const double state[], const double dstate_dt[], double resid[], std::vector< int > &off)=0
Residual Function for DAE Solver.
CPS::DAEInterface::daeInitialize
virtual Complex daeInitialize()=0
Voltage Getter for Components.
Generated by
1.13.2