import ofc.codegen._
object OnetepFunctions {
- val basis_copy_function_to_fftbox = new FortranSubroutineSignature("basis_copy_function_to_fftbox",
- Seq(("fa_fftbox", new ArrayType[FloatType](3)),
- ("fa_start1", new IntType),
- ("fa_start2", new IntType),
- ("fa_start3", new IntType),
+ val basis_copy_function_to_box = new FortranSubroutineSignature("basis_copy_function_to_box",
+ Seq(("fa_box", new ArrayType[FloatType](3)),
+ ("box_n1", new IntType),
+ ("box_n2", new IntType),
+ ("box_n3", new IntType),
+ ("offset1", new IntType),
+ ("offset2", new IntType),
+ ("offset3", new IntType),
("fa_tightbox", OnetepTypes.TightBox),
("fa_on_grid", new ArrayType[FloatType](1)),
("fa_sphere", OnetepTypes.Sphere)))
var basisCopyParams : Seq[Expression[_]] = Nil
basisCopyParams :+= (fftbox: Expression[ArrayType[FloatType]])
+ basisCopyParams ++= fftboxSize
basisCopyParams ++= fftboxOffset.map(new VarRef[IntType](_))
basisCopyParams :+= tightbox
basisCopyParams :+= (parent.data: Expression[ArrayType[FloatType]])
basisCopyParams :+= sphere
- context += new FunctionCallStatement(new FunctionCall(OnetepFunctions.basis_copy_function_to_fftbox, basisCopyParams))
+ context += new FunctionCallStatement(new FunctionCall(OnetepFunctions.basis_copy_function_to_box, basisCopyParams))
for (dim <- 0 to 2) yield {
import OnetepTypes._