Tissue Forge C++ 0.2.1
Interactive, particle-based physics, chemistry and biology modeling and simulation environment
Loading...
Searching...
No Matches
tfRigid.h
Go to the documentation of this file.
1/*******************************************************************************
2 * This file is part of mdcore.
3 * Coypright (c) 2010 Pedro Gonnet (pedro.gonnet@durham.ac.uk)
4 * Coypright (c) 2017 Andy Somogyi (somogyie at indiana dot edu)
5 * Copyright (c) 2022-2024 T.J. Sego
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU Lesser General Public License as published
9 * by the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU Lesser General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 *
20 ******************************************************************************/
21
27#ifndef _MDCORE_INCLUDE_TFRIGID_H_
28#define _MDCORE_INCLUDE_TFRIGID_H_
29#include "tf_platform.h"
30
31MDCORE_BEGIN_DECLS
32
33
34/* Some constants. */
35#define rigid_maxparts 10
36#define rigid_maxconstr (3*rigid_maxparts)
37#define rigid_maxiter 100
38#define rigid_pshake_refine 4
39#define rigid_pshake_maxalpha 0.1f
40
41
42namespace TissueForge {
43
44
46 typedef struct rigid {
47
50
52 int parts[ rigid_maxparts ];
53
56
58 struct {
59 int i, j;
60 FPTYPE d2;
61 } constr[ rigid_maxconstr ];
62
64 FPTYPE a[ rigid_maxconstr*rigid_maxconstr ];
65
67
68
69 /* associated functions */
70
79 HRESULT rigid_eval_shake(struct rigid *r, int N, struct engine *e);
80
89 HRESULT rigid_eval_pshake(struct rigid *r, int N, struct engine *e, int a_update);
90
91};
92
93MDCORE_END_DECLS
94#endif // _MDCORE_INCLUDE_TFRIGID_H_
Include Python header, disable linking to pythonX_d.lib on Windows in debug mode.
Definition tfAngleConfig.h:26
struct TissueForge::rigid rigid
HRESULT rigid_eval_pshake(struct rigid *r, int N, struct engine *e, int a_update)
Evaluate (P-SHAKE) a list of rigid constraints.
HRESULT rigid_eval_shake(struct rigid *r, int N, struct engine *e)
Evaluate (SHAKE) a list of rigid constraints.
Definition tfEngine.h:164
Definition tfRigid.h:46
int parts[10]
Definition tfRigid.h:52
struct TissueForge::rigid::@19 constr[(3 *10)]
int nr_parts
Definition tfRigid.h:49
FPTYPE a[(3 *10) *(3 *10)]
Definition tfRigid.h:64
int nr_constr
Definition tfRigid.h:55
int32_t HRESULT
Definition tf_port.h:255