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

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

Parent Directory Parent Directory | Revision Log Revision Log


Revision 776 - (show annotations)
Wed Jul 12 00:07:31 2006 UTC (12 years, 11 months ago) by gross
File MIME type: text/plain
File size: 2580 byte(s)
basic code for persistence of jacobeans added. routines are not called yet
1 /*
2 ************************************************************
3 * Copyright 2006 by ACcESS MNRF *
4 * *
5 * http://www.access.edu.au *
6 * Primary Business: Queensland, Australia *
7 * Licensed under the Open Software License version 3.0 *
8 * http://www.opensource.org/licenses/osl-3.0.php *
9 * *
10 ************************************************************
11 */
12
13 /**************************************************************/
14
15 /* Finley: Mesh: NodeFile */
16
17 /* copies the array newX into self->coordinates */
18
19 /**************************************************************/
20
21 /* Author: gross@access.edu.au */
22 /* Version: $Id$ */
23
24 /**************************************************************/
25
26 #include "NodeFile.h"
27 #include "Util.h"
28
29 /**************************************************************/
30
31
32 void Finley_NodeFile_setCoordinates(Finley_NodeFile* self,escriptDataC* newX) {
33 char error_msg[LenErrorMsg_MAX];
34 int n;
35 if (getDataPointSize(newX)!=self->numDim) {
36 sprintf(error_msg,"Finley_NodeFile_setCoordinates: dimension of new coordinates has to be %d.",self->numDim);
37 Finley_setError(VALUE_ERROR,error_msg);
38 } else if (! numSamplesEqual(newX,1,self->numNodes)) {
39 sprintf(error_msg,"Finley_NodeFile_setCoordinates: number of give nodes must to be %d.",self->numNodes);
40 Finley_setError(VALUE_ERROR,error_msg);
41 } else {
42 Finley_increaseStatus(self);
43 #pragma omp parallel for private(n) schedule(static)
44 for (n=0;n<self->numNodes;n++)
45 Finley_copyDouble(self->numDim,getSampleData(newX,n),&(self->Coordinates[INDEX2(0,n,self->numDim)]));
46 }
47 }
48 /*
49 * $Log$
50 * Revision 1.2 2005/09/15 03:44:23 jgs
51 * Merge of development branch dev-02 back to main trunk on 2005-09-15
52 *
53 * Revision 1.1.1.1.6.1 2005/09/07 06:26:20 gross
54 * the solver from finley are put into the standalone package paso now
55 *
56 * Revision 1.1.1.1 2004/10/26 06:53:57 jgs
57 * initial import of project esys2
58 *
59 * Revision 1.5 2004/08/26 12:03:52 gross
60 * Some other bug in Finley_Assemble_gradient fixed.
61 *
62 * Revision 1.4 2004/07/21 05:00:54 gross
63 * name changes in DataC
64 *
65 * Revision 1.3 2004/07/02 04:21:13 gross
66 * Finley C code has been included
67 *
68 * Revision 1.2 2004/07/01 23:54:32 gross
69 * used DataC now
70 *
71 * Revision 1.1.1.1 2004/06/24 04:00:40 johng
72 * Initial version of eys using boost-python.
73 *
74 *
75 */

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.26