Silverfrost Forums

Welcome to our forums

ASSEMBLY_INTERFACE generated subroutines & input names

1 Aug 2012 9:41 #10546

When I try to use in C# a Fortran subroutine I have two options:

Use the all caps subroutine or the subroutine defined by the assembly_interface statement.

The all caps subroutine has the problem that If there is a matrix as input or output I have to pass the size information.

The subroutine defined by the assembly_interface statement loses the input names!

Example:

http://img809.imageshack.us/img809/7137/ftn95.png

Matrices subroutine (just an example)

subroutine Matrices(f, A)
implicit none
ASSEMBLY_INTERFACE(Name='Matrices')

double precision, intent(in) :: f
double precision, intent(out):: A(:,:)

A      = 0.d0
A(1,1) = f
A(1,2) = f**2.d0

endsubroutine
Please login to reply.