-
Notifications
You must be signed in to change notification settings - Fork 98
/
TimeHistorySlipFn.i
100 lines (82 loc) · 2.77 KB
/
TimeHistorySlipFn.i
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
// -*- C++ -*-
//
// ----------------------------------------------------------------------
//
// Brad T. Aagaard, U.S. Geological Survey
// Charles A. Williams, GNS Science
// Matthew G. Knepley, University of Chicago
//
// This code was developed as part of the Computational Infrastructure
// for Geodynamics (http://geodynamics.org).
//
// Copyright (c) 2010-2012 University of California, Davis
//
// See COPYING for license information.
//
// ----------------------------------------------------------------------
//
/** @file modulesrc/faults/TimeHistorySlipFn.i
*
* @brief Python interface to C++ Fault object.
*/
namespace pylith {
namespace faults {
class TimeHistorySlipFn : public SlipTimeFn
{ // class TimeHistorySlipFn
// PUBLIC METHODS /////////////////////////////////////////////////
public :
/// Default constructor.
TimeHistorySlipFn(void);
/// Destructor.
~TimeHistorySlipFn(void);
/// Deallocate PETSc and local data structures.
virtual
void deallocate(void);
/** Set spatial database for amplitude of slip time history.
*
* @param db Spatial database
*/
void dbAmplitude(spatialdata::spatialdb::SpatialDB* const db);
/** Set spatial database for slip initiation time.
*
* @param db Spatial database
*/
void dbSlipTime(spatialdata::spatialdb::SpatialDB* const db);
/** Set time history.
*
* @param th Time history.
*/
void dbTimeHistory(spatialdata::spatialdb::TimeHistory* const th);
/** Initialize slip time function.
*
* @param faultMesh Finite-element mesh of fault.
* @param cs Coordinate system for mesh
* @param normalizer Nondimensionalization of scales.
* @param originTime Origin time for earthquake source.
*/
void initialize(const pylith::topology::SubMesh& faultMesh,
const spatialdata::units::Nondimensional& normalizer,
const PylithScalar originTime =0.0);
/** Get slip on fault surface at time t.
*
* @param slipField Slip field over fault surface.
* @param t Time t.
*
* @returns Slip vector as left-lateral/reverse/normal.
*/
void slip(pylith::topology::Field<pylith::topology::SubMesh>* const slipField,
const PylithScalar t);
/** Get final slip.
*
* @returns Final slip.
*/
const pylith::topology::Field<pylith::topology::SubMesh>& finalSlip(void);
/** Get time when slip begins at each point.
*
* @returns Time when slip begins.
*/
const pylith::topology::Field<pylith::topology::SubMesh>& slipTime(void);
}; // class TimeHistorySlipFn
} // faults
} // pylith
// End of file