- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Dear all,
this might be trivial for the f90 wizards soI apologise in advance for my
ignorance.
I want to use the MKL routine VDRNGUNIFORM to obtain vectors
of random numbers. The problem is, how to make the state variable STREAM, which is initialised by calling VSLNEWSTREAM in a separate subroutine global, so that it can be accessed by VDRNGUNIFORM in its own
routine. I cannot extend the argument listsof
the wrapper subroutines in which the MKL routines are called because their
format specification is prescribed by a project specification.
I tried to do this by common blocks in the wrapper routines:
TYPE (VSL_STREAM_STATE),POINTER :: stream
COMMON / randstate / stream
however, that results inthe followingcompiler error message
" If a common-block-object is of a derived type, it must be of a sequence type"
Any idea how to resolve this?
Karl
Ссылка скопирована
2 Ответы
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Oops, a google search for a f90 beginners guide was all needed to resolve
my question. Packing the declaration of stream in a module helped.
Sorry for the trivial post... Time to outgrow from f77 ;-)
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
So glad we could help :-)
Bruce
Ответить
Параметры темы
- Подписка на RSS-канал
- Отметить тему как новую
- Отметить тему как прочитанную
- Выполнить отслеживание данной Тема для текущего пользователя
- Закладка
- Подписаться
- Страница в формате печати