7.0
general documentation
cs_mesh_cartesian.h
Go to the documentation of this file.
1 #ifndef __CS_MESH_CARTESIAN_H__
2 #define __CS_MESH_CARTESIAN_H__
3 
4 /*============================================================================
5  * Cartesian mesh generation
6  *============================================================================*/
7 
8 /*
9  This file is part of Code_Saturne, a general-purpose CFD tool.
10 
11  Copyright (C) 1998-2021 EDF S.A.
12 
13  This program is free software; you can redistribute it and/or modify it under
14  the terms of the GNU General Public License as published by the Free Software
15  Foundation; either version 2 of the License, or (at your option) any later
16  version.
17 
18  This program is distributed in the hope that it will be useful, but WITHOUT
19  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
20  FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
21  details.
22 
23  You should have received a copy of the GNU General Public License along with
24  this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
25  Street, Fifth Floor, Boston, MA 02110-1301, USA.
26 */
27 
28 /*----------------------------------------------------------------------------
29  * Local headers
30  *----------------------------------------------------------------------------*/
31 
32 #include "cs_defs.h"
33 
34 /*============================================================================
35  * Type definitions
36  *============================================================================*/
37 
38 typedef enum {
39 
45 
47 
48 typedef struct _cs_mesh_cartesian_params_t cs_mesh_cartesian_params_t;
49 /*============================================================================
50  * Public C function prototypes
51  *============================================================================*/
52 
53 /*----------------------------------------------------------------------------*/
59 /*----------------------------------------------------------------------------*/
60 
61 cs_mesh_cartesian_params_t *
63 
64 /*----------------------------------------------------------------------------*/
67 /*----------------------------------------------------------------------------*/
68 
69 void
71 
72 /*----------------------------------------------------------------------------*/
81 /*----------------------------------------------------------------------------*/
82 
83 void
85  cs_real_t xyz[6]);
86 
87 /*----------------------------------------------------------------------------*/
95 /*----------------------------------------------------------------------------*/
96 
97 void
99  int ncells,
100  cs_real_t vtx_coord[]);
101 
102 /*----------------------------------------------------------------------------*/
118 /*----------------------------------------------------------------------------*/
119 
120 void
121 cs_mesh_cartesian_define_from_csv(const char *csv_file_name);
122 
123 /*----------------------------------------------------------------------------*/
135 /*----------------------------------------------------------------------------*/
136 
137 void
140  int ncells,
141  cs_real_t smin,
142  cs_real_t smax,
143  cs_real_t progression);
144 
145 /*----------------------------------------------------------------------------*/
150 /*----------------------------------------------------------------------------*/
151 
152 int
154 
155 /*----------------------------------------------------------------------------*/
162 /*----------------------------------------------------------------------------*/
163 
164 int
166 
167 /*----------------------------------------------------------------------------*/
174 /*----------------------------------------------------------------------------*/
175 
176 void
178  cs_mesh_builder_t *mb,
179  long echo);
180 
181 /*----------------------------------------------------------------------------*/
184 /*----------------------------------------------------------------------------*/
185 
186 void
188 
189 /*----------------------------------------------------------------------------*/
190 
191 #endif /* __CS_MESH_CARTESIAN_H__ */
void cs_mesh_cartesian_define_dir_params(int idim, cs_mesh_cartesian_law_t law, int ncells, cs_real_t smin, cs_real_t smax, cs_real_t progression)
Define parameters for a given direction.
Definition: cs_mesh_cartesian.c:673
Definition: cs_mesh_builder.h:57
void cs_mesh_cartesian_define_simple(int ncells[3], cs_real_t xyz[6])
Define a simple cartesian mesh with a constant step in all directions.
Definition: cs_mesh_cartesian.c:494
Definition: cs_mesh_cartesian.h:41
int cs_mesh_cartesian_get_ncells(int idim)
Get number of cells in a given direction.
Definition: cs_mesh_cartesian.c:741
double cs_real_t
Floating-point value.
Definition: cs_defs.h:307
Definition: cs_mesh.h:84
Definition: cs_mesh_cartesian.h:42
void cs_mesh_cartesian_params_destroy(void)
Destroy cartesian mesh parameters.
Definition: cs_mesh_cartesian.c:922
void cs_mesh_cartesian_define_dir_user(int idir, int ncells, cs_real_t vtx_coord[])
Define directions parameters based on a user input.
Definition: cs_mesh_cartesian.c:524
int cs_mesh_cartesian_need_build(void)
Indicate if a cartesian mesh is to be built.
Definition: cs_mesh_cartesian.c:724
void cs_mesh_cartesian_create(void)
Create cartesian mesh structure.
Definition: cs_mesh_cartesian.c:475
integer(c_int), pointer, save smin
starting min
Definition: atincl.f90:196
Definition: cs_mesh_cartesian.h:43
cs_mesh_cartesian_params_t * cs_mesh_cartesian_get_params(void)
Return pointer to cartesian mesh parameters structure.
Definition: cs_mesh_cartesian.c:464
void cs_mesh_cartesian_connectivity(cs_mesh_t *m, cs_mesh_builder_t *mb, long echo)
Build unstructured connectivity needed for partitionning.
Definition: cs_mesh_cartesian.c:756
void cs_mesh_cartesian_define_from_csv(const char *csv_file_name)
Define a simple cartesian mesh based on a CSV file. CSV file needs to contain : (1) First line which ...
Definition: cs_mesh_cartesian.c:573
Definition: cs_mesh_cartesian.h:44
cs_mesh_cartesian_law_t
Definition: cs_mesh_cartesian.h:38
Definition: cs_mesh_cartesian.h:40