/[escript]/trunk/finley/src/Assemble_NodeCoordinates.c
ViewVC logotype

Contents of /trunk/finley/src/Assemble_NodeCoordinates.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 155 - (show annotations)
Wed Nov 9 02:02:19 2005 UTC (13 years, 11 months ago) by jgs
Original Path: trunk/finley/src/finleyC/Assemble_NodeCoordinates.c
File MIME type: text/plain
File size: 3374 byte(s)
move all directories from trunk/esys2 into trunk and remove esys2

1 /*
2 ******************************************************************************
3 * *
4 * COPYRIGHT ACcESS 2003,2004,2005 - All Rights Reserved *
5 * *
6 * This software is the property of ACcESS. No part of this code *
7 * may be copied in any form or by any means without the expressed written *
8 * consent of ACcESS. Copying, use or modification of this software *
9 * by any unauthorised person is illegal unless that person has a software *
10 * license agreement with ACcESS. *
11 * *
12 ******************************************************************************
13 */
14
15 /**************************************************************/
16
17 /* assemblage routines: copies node coordinates into an expanded Data Object */
18
19 /**************************************************************/
20
21 /* Copyrights by ACcESS Australia 2003,2004,2005 */
22 /* Version: $Id$ */
23
24 /**************************************************************/
25
26 #include "Util.h"
27 #include "Assemble.h"
28 #ifdef _OPENMP
29 #include <omp.h>
30 #endif
31
32 /**************************************************************/
33
34 void Finley_Assemble_NodeCoordinates(Finley_NodeFile* nodes,escriptDataC* x) {
35 char error_msg[LenErrorMsg_MAX];
36 dim_t n;
37 Finley_resetError();
38 if (nodes==NULL) return;
39 if (! numSamplesEqual(x,1,nodes->numNodes)) {
40 Finley_setError(TYPE_ERROR,"__FILE__: illegal number of samples of Data object");
41 } else if (getFunctionSpaceType(x)!=FINLEY_NODES) {
42 Finley_setError(TYPE_ERROR,"__FILE__: Data object is not defined on nodes.");
43 } else if (! isExpanded(x)) {
44 Finley_setError(TYPE_ERROR,"__FILE__: expanded Data object expected");
45 } else if (! isDataPointShapeEqual(x,1, &(nodes->numDim))) {
46 sprintf(error_msg,"__FILE__: Data object of shape (%d,) expected",nodes->numDim);
47 Finley_setError(TYPE_ERROR,error_msg);
48 } else {
49 #pragma omp parallel for private(n)
50 for (n=0;n<nodes->numNodes;n++)
51 Finley_copyDouble(nodes->numDim,&(nodes->Coordinates[INDEX2(0,n,nodes->numDim)]),getSampleData(x,n));
52 }
53 }
54 /*
55 * $Log$
56 * Revision 1.3 2005/09/15 03:44:21 jgs
57 * Merge of development branch dev-02 back to main trunk on 2005-09-15
58 *
59 * Revision 1.2.2.1 2005/09/07 06:26:17 gross
60 * the solver from finley are put into the standalone package paso now
61 *
62 * Revision 1.2 2005/07/08 04:07:45 jgs
63 * Merge of development branch back to main trunk on 2005-07-08
64 *
65 * Revision 1.1.1.1.2.1 2005/06/29 02:34:46 gross
66 * some changes towards 64 integers in finley
67 *
68 * Revision 1.1.1.1 2004/10/26 06:53:57 jgs
69 * initial import of project esys2
70 *
71 * Revision 1.5 2004/08/26 12:03:52 gross
72 * Some other bug in Finley_Assemble_gradient fixed.
73 *
74 * Revision 1.4 2004/08/05 03:58:27 gross
75 * Bug in Assemble_NodeCoordinates fixed
76 *
77 * Revision 1.3 2004/07/30 04:37:06 gross
78 * escript and finley are linking now and RecMeshTest.py has been passed
79 *
80 * Revision 1.2 2004/07/21 05:00:54 gross
81 * name changes in DataC
82 *
83 * Revision 1.1 2004/07/02 04:21:13 gross
84 * Finley C code has been included
85 *
86 *
87 */

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

  ViewVC Help
Powered by ViewVC 1.1.26