OpenCMISS-Iron Internal API Documentation
coordinate_routines.f90 File Reference

This module contains all coordinate transformation and support routines. More...

Go to the source code of this file.

Data Types

type  coordinate_routines::coordinate_systems_type
 
interface  coordinate_routines::coordinate_convert_from_rc
 COORDINATE_CONVERT_FROM_RC performs a coordinate transformation from a rectangular cartesian coordinate at the point with coordinate Z(:) to the returned point with coordinate X(:) in the coordinate system identified by COORDINATE_SYSTEM. More...
 
interface  coordinate_routines::coordinate_convert_to_rc
 COORDINATE_CONVERT_TO_RC performs a coordinate transformation from a coordinate system identified by COORDINATE_SYSTEM at the point X(:) to the returned point Z(:) in rectangular cartesian coordinates. More...
 
interface  coordinate_routines::coordinate_delta_calculate
 Calculates the difference (or delta) between two points in a coordinate system. Discontinuities for polar coordinate systems are accounted for. More...
 
interface  coordinate_routines::dxz
 Calculates DX(:)/DZ(I) at X, where Z(I) are rectangular cartesian and X(:) are curvilinear coordinates defined by COORDINATE_SYSTEM. More...
 
interface  coordinate_routines::d2zx
 
interface  coordinate_routines::dzx
 
interface  coordinate_routines::coordinate_derivative_convert_to_rc
 

Modules

module  coordinate_routines
 This module contains all coordinate transformation and support routines.
 

Functions/Subroutines

real(dp) function, dimension(size(z, 1)) coordinate_routines::coordinate_convert_from_rc_dp (COORDINATE_SYSTEM, Z, ERR, ERROR)
 Performs a coordinate transformation from a rectangular cartesian coordinate at the point with coordinate Z(:) to the returned point with coordinate X(:) in the coordinate system identified by COORDINATE_SYSTEM for double precision coordinates. More...
 
real(sp) function, dimension(size(z, 1)) coordinate_routines::coordinate_convert_from_rc_sp (COORDINATE_SYSTEM, Z, ERR, ERROR)
 COORDINATE_CONVERT_FROM_RC_SP performs a coordinate transformation from a rectangular cartesian coordinate at the point with coordinate Z(:) to the returned point with coordinate X(:) in the coordinate system identified by COORDINATE_SYSTEM for single precision coordinates. More...
 
real(dp) function, dimension(size(x, 1)) coordinate_routines::coordinate_convert_to_rc_dp (COORDINATE_SYSTEM, X, ERR, ERROR)
 COORDINATE_CONVERT_TO_RC_DP performs a coordinate transformation from a coordinate system identified by COORDINATE_SYSTEM at the point X(:) to the returned point Z(:) in rectangular cartesian coordinates for double precision coordinates. More...
 
real(sp) function, dimension(size(x, 1)) coordinate_routines::coordinate_convert_to_rc_sp (COORDINATE_SYSTEM, X, ERR, ERROR)
 COORDINATE_CONVERT_TO_RC_SP performs a coordinate transformation from a coordinate system identified by COORDINATE_SYSTEM at the point X(:) to the returned point Z(:) in rectangular cartesian coordinates for single precision coordinates. More...
 
real(dp) function, dimension(size(x, 1)) coordinate_routines::coordinate_delta_calculate_dp (COORDINATE_SYSTEM, X, Y, ERR, ERROR)
 Calculates the difference (or detlta) between the point X and the point Y i.e., Y-X, in the given coordinate system. 0->2Pi discontinuities with polar coordinates are accounted for. More...
 
subroutine, public coordinate_routines::coordinate_metrics_calculate (COORDINATE_SYSTEM, JACOBIAN_TYPE, METRICS, ERR, ERROR,)
 Calculates the covariant metric tensor GL(i,j), the contravariant metric tensor GU(i,J), the Jacobian and derivative of the interpolated coordinate system (XI_i) with respect to the given coordinate (X_j) system (DXI_DX) at a point (X - normally a Gauss point). Old cmiss name: XGMG. More...
 
subroutine coordinate_routines::coordinate_system_normal_calculate (COORDINATE_SYSTEM, REVERSE, X, N, ERR, ERROR,)
 Calculates the normal vector, N, at the point X. IF REVERSE is true the reversed normal is returned. Old-cmiss-name: NORMAL. More...
 
subroutine, public coordinate_routines::coordinate_system_dimension_get (COORDINATE_SYSTEM, NUMBER_OF_DIMENSIONS, ERR, ERROR,)
 Gets the coordinate system dimension. More...
 
subroutine coordinate_routines::coordinate_system_finalise (COORDINATE_SYSTEM, ERR, ERROR,)
 Finalises a coordinate system and deallocates all memory. More...
 
subroutine, public coordinate_routines::coordinate_system_focus_get (COORDINATE_SYSTEM, FOCUS, ERR, ERROR,)
 Returns the coordinate system focus. More...
 
subroutine, public coordinate_routines::coordinates_radialinterpolationtypeget (coordinateSystem, radialInterpolationType, err, error,)
 Gets the coordinate system radial interpolation type. More...
 
subroutine, public coordinate_routines::coordinate_system_type_get (COORDINATE_SYSTEM, SYSTEM_TYPE, ERR, ERROR,)
 Gets the coordinate system type. More...
 
subroutine, public coordinate_routines::coordinate_system_dimension_set (COORDINATE_SYSTEM, DIMENSION, ERR, ERROR,)
 Sets/changes the dimension of the coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_focus_set (COORDINATE_SYSTEM, FOCUS, ERR, ERROR,)
 Sets/changes the focus of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinates_radialinterpolationtypeset (coordinateSystem, radialInterpolationType, err, error,)
 Sets/changes the radial interpolation type of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_type_set (COORDINATE_SYSTEM, TYPE, ERR, ERROR,)
 Sets/changes the type of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_origin_get (COORDINATE_SYSTEM, ORIGIN, ERR, ERROR,)
 Returns the origin of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_origin_set (COORDINATE_SYSTEM, ORIGIN, ERR, ERROR,)
 Sets/changes the origin of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_orientation_get (COORDINATE_SYSTEM, ORIENTATION, ERR, ERROR,)
 Returns the orientation of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_orientation_set (COORDINATE_SYSTEM, ORIENTATION, ERR, ERROR,)
 Sets/changes the orientation of a coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_create_start (USER_NUMBER, COORDINATE_SYSTEM, ERR, ERROR,)
 Starts the creation of and initialises a new coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_create_finish (COORDINATE_SYSTEM, ERR, ERROR,)
 Finishes the creation of a new coordinate system. More...
 
subroutine, public coordinate_routines::coordinate_system_destroy (COORDINATE_SYSTEM, ERR, ERROR,)
 Destroys a coordinate system. More...
 
real(dp) function, dimension(size(x, 1)) coordinate_routines::dxz_dp (COORDINATE_SYSTEM, I, X, ERR, ERROR)
 Calculates DX(:)/DZ(I) at X, where Z(I) are rectangular cartesian and X(:) are curvilinear coordinates defined by COORDINATE_SYSTEM for double precision coordinates. More...
 
real(dp) function, dimension(size(x, 1)) coordinate_routines::d2zx_dp (COORDINATE_SYSTEM, I, J, X, ERR, ERROR)
 
real(dp) function, dimension(size(x, 1)) coordinate_routines::dzx_dp (COORDINATE_SYSTEM, I, X, ERR, ERROR)
 
subroutine coordinate_routines::coordinate_derivative_convert_to_rc_dp (COORDINATE_SYSTEM, PART_DERIV_TYPE, X, Z, ERR, ERROR,)
 
subroutine coordinate_routines::coordinate_derivative_convert_to_rc_sp (COORDINATE_SYSTEM, PART_DERIV_TYPE, X, Z, ERR, ERROR,)
 
subroutine, public coordinate_routines::coordinate_derivative_norm (COORDINATE_SYSTEM, PART_DERIV_INDEX, INTERPOLATED_POINT, DERIV_NORM, ERR, ERROR,)
 Calculates the norm of a derivative in a coordinate system identified by COORDINATE_SYSTEM at the given interpolated point and returns the value in NORM for single precision coordinates. PART_DERIV_INDEX is used to select the appropriate partial derivative (i.e., wrt S1, S2 or S3) to normalise. More...
 
subroutine, public coordinate_routines::coordinate_interpolation_adjust (COORDINATE_SYSTEM, PARTIAL_DERIVATIVE_INDEX, VALUE, ERR, ERROR,)
 Adjusts the interpolation for non-rectangular cartesian coordinate systems. More...
 
subroutine, public coordinate_routines::coordinate_interpolation_parameters_adjust (COORDINATE_SYSTEM, INTERPOLATION_PARAMETERS, ERR, ERROR,)
 Adjusts the interpolation parameters for non-rectangular cartesian coordinate systems. More...
 
subroutine, public coordinate_routines::coordinates_materialsystemcalculate (geometricInterpPointMetrics, fibreInterpPoint, dNudX, dXdNu, dNudXi, dXidNu, err, error,)
 Calculates the tensor to get from material coordinate system, nu, to local coordinate system, xi. More...
 
subroutine coordinate_routines::coordinates_materialsystemcalculatedxdnu2d (geometricInterpPointMetrics, angle, dXdNu, err, error,)
 Calculates transformation between spatial CS and rotated reference orthogonal material CS in 2D space. More...
 
subroutine coordinate_routines::coordinates_materialsystemcalculatedxdnu3d (geometricInterpPointMetrics, angle, dXdNu, err, error,)
 Calculates transformation between spatial CS and rotated reference orthogonal material CS in 3D space. More...
 
subroutine, public coordinate_routines::coordinate_system_user_number_find (USER_NUMBER, COORDINATE_SYSTEM, ERR, ERROR,)
 Returns a pointer to the coordinate system identified by USER_NUMBER. If a coordinate system with that number is not found then COORDINATE_SYSTEM is set to NULL. More...
 
subroutine, public coordinate_routines::coordinate_systems_finalise (ERR, ERROR,)
 Finalises the coordinate systems and destroys all coordinate systems. More...
 
subroutine, public coordinate_routines::coordinate_systems_initialise (ERR, ERROR,)
 Initialises the coordinate systems and creates the world coordinate system. More...
 

Variables

integer(intg), parameter, public coordinate_routines::coordinate_rectangular_cartesian_type =1
 Rectangular Cartesian coordinate system type. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_cylindrical_polar_type =2
 Cylindrical polar coordinate system type. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_spherical_polar_type =3
 Spherical polar coordinate system type. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_prolate_spheroidal_type =4
 Prolate spheroidal coordinate system type. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_oblate_spheroidal_type =5
 Oblate spheroidal coordinate system type. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_no_radial_interpolation_type =0
 No radial interpolation. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_radial_interpolation_type =1
 r radial interpolation More...
 
integer(intg), parameter, public coordinate_routines::coordinate_radial_squared_interpolation_type =2
 r^2 radial interpolation More...
 
integer(intg), parameter, public coordinate_routines::coordinate_radial_cubed_interpolation_type =3
 r^3 radial interpolation More...
 
integer(intg), parameter, public coordinate_routines::coordinate_jacobian_no_type =0
 No Jacobian. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_jacobian_line_type =1
 Line type Jacobian. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_jacobian_area_type =2
 Area type Jacobian. More...
 
integer(intg), parameter, public coordinate_routines::coordinate_jacobian_volume_type =3
 Volume type Jacobian. More...
 
character(len=21), dimension(5), public coordinate_routines::coordinate_system_type_string = (/ "Rectangular Cartesian", "Cylindrical Polar ", "Spherical Polar ", "Prolate Spheroidal ", "Oblate Spheroidal " /)
 
type(coordinate_systems_type) coordinate_routines::coordinate_systems
 

Detailed Description

This module contains all coordinate transformation and support routines.

Author
Chris Bradley

LICENSE

Version: MPL 1.1/GPL 2.0/LGPL 2.1

The contents of this file are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/

Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.

The Original Code is OpenCMISS

The Initial Developer of the Original Code is University of Auckland, Auckland, New Zealand, the University of Oxford, Oxford, United Kingdom and King's College, London, United Kingdom. Portions created by the University of Auckland, the University of Oxford and King's College, London are Copyright (C) 2007-2010 by the University of Auckland, the University of Oxford and King's College, London. All Rights Reserved.

Contributor(s): Kumar Mithraratne

Alternatively, the contents of this file may be used under the terms of either the GNU General Public License Version 2 or later (the "GPL"), or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), in which case the provisions of the GPL or the LGPL are applicable instead of those above. If you wish to allow use of your version of this file only under the terms of either the GPL or the LGPL, and not to allow others to use your version of this file under the terms of the MPL, indicate your decision by deleting the provisions above and replace them with the notice and other provisions required by the GPL or the LGPL. If you do not delete the provisions above, a recipient may use your version of this file under the terms of any one of the MPL, the GPL or the LGPL.

Definition in file coordinate_routines.f90.