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

Annotation of /trunk/finley/src/NodeFile_copyTable.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 471 - (hide annotations)
Fri Jan 27 01:33:02 2006 UTC (13 years, 8 months ago) by jgs
File MIME type: text/plain
File size: 2852 byte(s)
reorganise finley src tree to remove inc dir and src/finley directory

1 jgs 150 /*
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 jgs 82 /**************************************************************/
16    
17     /* Finley: Mesh: NodeFile */
18    
19     /* copies node file in into node file out starting from offset */
20     /* the nodes offset to in->numNodes+offset-1 in out will be overwritten */
21    
22    
23     /**************************************************************/
24    
25     /* Author: gross@access.edu.au */
26     /* Version: $Id$ */
27    
28     /**************************************************************/
29    
30     #include "NodeFile.h"
31    
32     /**************************************************************/
33    
34     void Finley_NodeFile_copyTable(int offset,Finley_NodeFile* out,int idOffset,int dofOffset,Finley_NodeFile* in) {
35     int i,n;
36     /* check dimension and file size */
37     if (out->numDim!=in->numDim) {
38 jgs 150 Finley_setError(TYPE_ERROR,"__FILE__: dimensions of node files don't match");
39 jgs 82 }
40     if (out->numNodes<in->numNodes+offset) {
41 jgs 150 Finley_setError(MEMORY_ERROR,"__FILE__: node table is too small.");
42 jgs 82 }
43 jgs 150 if (Finley_noError()) {
44 jgs 82 #pragma omp parallel for private(i,n) schedule(static)
45     for(n=0;n<in->numNodes;n++) {
46     out->Id[offset+n]=in->Id[n]+idOffset;
47     out->Tag[offset+n]=in->Tag[n];
48     out->degreeOfFreedom[offset+n]=in->degreeOfFreedom[n]+dofOffset;
49     out->reducedDegreeOfFreedom[offset+n]=in->reducedDegreeOfFreedom[n]+dofOffset;
50     out->toReduced[offset+n]=in->toReduced[n]+dofOffset;
51     for(i=0;i<out->numDim;i++) out->Coordinates[INDEX2(i,offset+n,out->numDim)]=in->Coordinates[INDEX2(i,n,in->numDim)];
52     }
53     }
54     }
55     /*
56     * $Log$
57 jgs 150 * Revision 1.2 2005/09/15 03:44:23 jgs
58     * Merge of development branch dev-02 back to main trunk on 2005-09-15
59 jgs 82 *
60 jgs 150 * Revision 1.1.1.1.6.1 2005/09/07 06:26:20 gross
61     * the solver from finley are put into the standalone package paso now
62     *
63     * Revision 1.1.1.1 2004/10/26 06:53:57 jgs
64     * initial import of project esys2
65     *
66 jgs 82 * Revision 1.1.1.1 2004/06/24 04:00:40 johng
67     * Initial version of eys using boost-python.
68     *
69     *
70     */

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.26