-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinterface.h
More file actions
40 lines (32 loc) · 753 Bytes
/
Copy pathinterface.h
File metadata and controls
40 lines (32 loc) · 753 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/*
* interface.h
*
* Jun Korenaga, MIT/WHOI
* January 1999
*/
#ifndef _TOMO_INTERFACE_H_
#define _TOMO_INTERFACE_H_
#include <array.h>
#include "smesh.h"
class Interface2d {
public:
Interface2d(){}
Interface2d(const SlownessMesh2d&);
Interface2d(const char*);
double z(double x) const;
double dzdx(double x) const;
void locateInSegment(double, int&, int&) const;
double x(int) const;
double xmin() const;
double xmax() const;
int numNodes() const;
void set(const Array1d<double>&);
void get(Array1d<double>&) const;
friend ostream&
operator<<(ostream&, const Interface2d&);
private:
void calc_slope();
static const double eps;
Array1d<double> xpos, zpos, slope;
};
#endif