Skip to content

Commit

Permalink
Add JOSS paper (#203)
Browse files Browse the repository at this point in the history
* added initial joss paper

* added GHA

* added some basic summary

* start parametric tools section

* actually commit the paper

* mystery paragraph

* constraints

* added FFD section

* constraints

* whitespace

* format fixes

* cst

* fix constraints

* wording

* start examples

* started statement of need

* added some comments

* clarify esp/vsp need

* Updated DVGeoCST description

* esp/vsp process

* expanded FFD a bit

* added some short text on parallelism and gradients

* added DVGeoMulti description and figure

* edited ffd derivatives

* comments and edits up to geometry parametrization

* added description of children FFDs, to be reviewed

* addressed a few marco comments

* removed references to module names

* esp and vsp pictures,  children FFD-> child FFD

* clarifying solver independence

* added authors

* Make global FFD DV figures nicer

* Added CST figure

* include cst figure, ffd figure works slightly better

* trying to fix FFD DV figure

* pdfs

* started geometry generation section + pic

* geometry generation

* fix figure

* orcid

* captions

* minor edits

* orcids

* josh edits (#172)

* josh edits

* add missed edit

* minor updates to Josh edits

Co-authored-by: Hannah Hajdik <hajdik@umich.edu>

* Sabet JOSS paper edits (#173)

* edits through FFD

* finished edits and added todos

* higher resolution images from papers

* addressed some Sabet todos

* condense parametric geometry section

* talking to Sabet

Co-authored-by: Hannah Hajdik <hajdik@umich.edu>

* Finished my edits. Please check all my changes to make sure I did not change the meaning or introduce innacuracis. Check and respond to the TODOs.

* fixed figure labels

* updated multi FFD figure

* minor changes

* Marco's paper edits (#174)

* rephrased abstract -  MDO not only aerostructural

* edits up to hierarchical FFD

* minor fixes up to cst

* some details and comments on constraints

* more reprasings suggestions and commments

* finalize marco edits

Co-authored-by: Hannah Hajdik <hajdik@umich.edu>

* added Lyu 2014 BWB paper citation

* added CST derivatives

* Joss paper anil's edits (#175)

* anil edits

* fixed footnotes

* some anil todos

* take out geometry generation

* constraint figure

---------

Co-authored-by: Sabet Seraj <48863473+sseraj@users.noreply.github.com>
Co-authored-by: Hannah Hajdik <hajdik@umich.edu>

* Ben B edits and additions to the paper

* Misc. edits (#184)

* josh edits

* add missed edit

* cleaning up extra detail

* cropped figure for triangulated surface constraint

* new figures for child ffd & trisurfcon

* delete old versions of figures

* removed abstracts in bib file

* small edits

* cleaned up some comments

* neil comments

* removing old TODOs

* saved old sections elsewhere and deleted comments

* deleted old comments

* sabet todo

* clarifying

* fixed sabet's todo. with sabet. todone.

* anil said it's fine

* redid summary & statement of need with sabet

---------

Co-authored-by: Josh Anibal <joanibal@umich.edu>
Co-authored-by: Neil Wu <neilwu0626@gmail.com>

* removed paper pdf

* updated bib

* move SVD reference

* standardize name formats

* zenodo metadata

* version bump

* formatting

* isort again

* even more sorted

* comments?

* another one

* Finished my edits.

* grammar/format

* A few more edits.

* A few more edits.

* sabet comments

* zenodo metadata

* quim comments

* citation and acronym fixes

* citation again

* remove yml

---------

Co-authored-by: Neil Wu <602725+nwu63@users.noreply.github.com>
Co-authored-by: eytanadler <eytana@umich.edu>
Co-authored-by: Marco Mangano <mmangano@umich.edu>
Co-authored-by: Alasdair Gray <alachris@umich.edu>
Co-authored-by: Josh Anibal <joanibal@umich.edu>
Co-authored-by: Sabet Seraj <48863473+sseraj@users.noreply.github.com>
Co-authored-by: Joaquim Martins <jrram@umich.edu>
Co-authored-by: Marco Mangano <36549388+marcomangano@users.noreply.github.com>
Co-authored-by: Anil Yildirim <42349285+anilyil@users.noreply.github.com>
Co-authored-by: Ben Brelje <benjamin.brelje@gmail.com>
  • Loading branch information
11 people authored Jun 9, 2023
1 parent 4f18d04 commit 2827954
Show file tree
Hide file tree
Showing 15 changed files with 771 additions and 1 deletion.
41 changes: 41 additions & 0 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"creators": [
{
"name": "Hannah M. Hajdik"
},
{
"name": "Anil Yildirim"
},
{
"name": "Neil Wu"
},
{
"name": "Benjamin J. Brelje"
},
{
"name": "Sabet Seraj"
},
{
"name": "Marco Mangano"
},
{
"name": "Joshua L. Anibal"
},
{
"name": "Eirikur Jonsson"
},
{
"name": "Eytan J. Adler"
},
{
"name": "Charles A. Mader"
},
{
"name": "Gaetan K. W. Kenway"
},
{
"name": "Joaquim R. R. A. Martins"
}
],
"title": "pyGeo: A geometry package for multidisciplinary design optimization",
}
59 changes: 59 additions & 0 deletions paper/Global-FFD-DV-Demo.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Standard Python modules
import copy

# External modules
import numpy as np

# First party modules
from pygeo import DVGeometry

FFDFile = "ffd.xyz"
DVGeo = DVGeometry(FFDFile)

nRefAxPts = DVGeo.addRefAxis("wing", xFraction=0.25, alignIndex="k")


def dihedral(val, geo):
C = geo.extractCoef("wing")
for i in range(1, nRefAxPts):
C[i, 1] += val[i - 1]
geo.restoreCoef(C, "wing")


# rst Twist
def twist(val, geo):
for i in range(1, nRefAxPts):
geo.rot_z["wing"].coef[i] = val[i - 1]


# rst Taper
def taper(val, geo):
s = geo.extractS("wing")
slope = (val[1] - val[0]) / (s[-1] - s[0])
for i in range(nRefAxPts):
geo.scale_x["wing"].coef[i] = slope * (s[i] - s[0]) + val[0]


nTwist = nRefAxPts - 1
DVGeo.addGlobalDV(dvName="dihedral", value=[0] * nTwist, func=dihedral, lower=-10, upper=10, scale=1)
DVGeo.addGlobalDV(dvName="twist", value=[0] * nTwist, func=twist, lower=-10, upper=10, scale=1)
DVGeo.addGlobalDV(dvName="taper", value=[1] * 2, func=taper, lower=0.5, upper=1.5, scale=1)

# Comment out one or the other
DVGeo.addLocalDV("local", lower=-0.5, upper=0.5, axis="y", scale=1)

dvDict = DVGeo.getValues()
dvDictCopy = copy.deepcopy(dvDict)
dvDictCopy["twist"] = np.linspace(0, 50, nRefAxPts)[1:]
DVGeo.setDesignVars(dvDictCopy)
DVGeo.writePlot3d("ffd_deformed-twist.xyz")

dvDictCopy = copy.deepcopy(dvDict)
dvDictCopy["dihedral"] = np.linspace(0, 3, nRefAxPts)[1:]
DVGeo.setDesignVars(dvDictCopy)
DVGeo.writePlot3d("ffd_deformed-dihedral.xyz")

dvDictCopy = copy.deepcopy(dvDict)
dvDictCopy["taper"] = np.array([1.2, 0.5])
DVGeo.setDesignVars(dvDictCopy)
DVGeo.writePlot3d("ffd_deformed-taper.xyz")
Binary file added paper/child_ffd.pdf
Binary file not shown.
Binary file added paper/constraints_3d.pdf
Binary file not shown.
Binary file added paper/cst_example.pdf
Binary file not shown.
51 changes: 51 additions & 0 deletions paper/cst_example.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Standard Python modules
import os

# External modules
import matplotlib.pyplot as plt
import numpy as np

# First party modules
from pygeo.parameterization.DVGeoCST import DVGeometryCST

cur_dir = os.path.dirname(os.path.abspath(__file__))
out_file = os.path.join(cur_dir, "cst_example.pdf")

# Airfoil shape inputs
x = np.linspace(0, 1, 10000)
N1 = 0.5
N2 = 1.0
yte = 0.0
num_cst = 3
coeff = [
{"upper": np.full(num_cst, 0.5), "lower": np.full(num_cst, 0.5)},
{"upper": np.array([1.5, 0.5, 0.5]), "lower": np.full(num_cst, 0.5)},
]

# Line styles
colors = ["#0CAAEF", "#003268"]
poly_linewidth = 0.8
alpha = 0.5

fig, axs = plt.subplots(1, 2, figsize=[5.5, 2])

for i_foil, c in enumerate(coeff):
for surf, color in zip(["upper", "lower"], colors):
for i in range(num_cst):
w = np.zeros(num_cst)
w[i] = c[surf][i]
y = DVGeometryCST.computeCSTCoordinates(x, N1, N2, w, yte)
y = -y if surf == "lower" else y
axs[i_foil].plot(x, y, color=color, linewidth=poly_linewidth, alpha=alpha)

y = DVGeometryCST.computeCSTCoordinates(x, N1, N2, c[surf], yte)
y = -y if surf == "lower" else y
axs[i_foil].plot(x, y, color=color)

axs[i_foil].set_aspect("equal")
axs[i_foil].axis("off")
axs[i_foil].set_ylim([-0.2, 0.45])

plt.subplots_adjust(left=0, right=1, bottom=0, top=1, wspace=0.0)

fig.savefig(out_file)
Binary file added paper/esp_example.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 50 additions & 0 deletions paper/ffd.xyz
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
1
6 2 8
-0.10000000 0.94000000 1.98000000 3.02000000 4.06000000 5.10000000
-0.10000000 0.94000000 1.98000000 3.02000000 4.06000000 5.10000000
1.48118553 2.37782471 3.27446389 4.17110307 5.06774224 5.96438142
1.48118553 2.37782471 3.27446389 4.17110307 5.06774224 5.96438142
2.65300391 3.44339822 4.23379253 5.02418685 5.81458116 6.60497547
2.65300391 3.44339822 4.23379253 5.02418685 5.81458116 6.60497547
3.70785003 4.40260496 5.09735989 5.79211482 6.48686975 7.18162468
3.70785003 4.40260496 5.09735989 5.79211482 6.48686975 7.18162468
4.69325821 5.29866946 5.90408072 6.50949197 7.11490323 7.72031449
4.69325821 5.29866946 5.90408072 6.50949197 7.11490323 7.72031449
5.63005558 6.15053054 6.67100550 7.19148047 7.71195543 8.23243039
5.63005558 6.15053054 6.67100550 7.19148047 7.71195543 8.23243039
6.52985197 6.96874539 7.40763881 7.84653223 8.28542566 8.72431908
6.52985197 6.96874539 7.40763881 7.84653223 8.28542566 8.72431908
7.40000000 7.76000000 8.12000000 8.48000000 8.84000000 9.20000000
7.40000000 7.76000000 8.12000000 8.48000000 8.84000000 9.20000000
-0.50000000 -0.50000000 -0.50000000 -0.50000000 -0.50000000 -0.50000000
0.50000000 0.50000000 0.50000000 0.50000000 0.50000000 0.50000000
-0.44729382 -0.44729382 -0.44729382 -0.44729382 -0.44729382 -0.44729382
0.44729382 0.44729382 0.44729382 0.44729382 0.44729382 0.44729382
-0.40823320 -0.40823320 -0.40823320 -0.40823320 -0.40823320 -0.40823320
0.40823320 0.40823320 0.40823320 0.40823320 0.40823320 0.40823320
-0.37307167 -0.37307167 -0.37307167 -0.37307167 -0.37307167 -0.37307167
0.37307167 0.37307167 0.37307167 0.37307167 0.37307167 0.37307167
-0.34022473 -0.34022473 -0.34022473 -0.34022473 -0.34022473 -0.34022473
0.34022473 0.34022473 0.34022473 0.34022473 0.34022473 0.34022473
-0.30899815 -0.30899815 -0.30899815 -0.30899815 -0.30899815 -0.30899815
0.30899815 0.30899815 0.30899815 0.30899815 0.30899815 0.30899815
-0.27900493 -0.27900493 -0.27900493 -0.27900493 -0.27900493 -0.27900493
0.27900493 0.27900493 0.27900493 0.27900493 0.27900493 0.27900493
-0.25000000 -0.25000000 -0.25000000 -0.25000000 -0.25000000 -0.25000000
0.25000000 0.25000000 0.25000000 0.25000000 0.25000000 0.25000000
-0.01000000 -0.01000000 -0.01000000 -0.01000000 -0.01000000 -0.01000000
-0.01000000 -0.01000000 -0.01000000 -0.01000000 -0.01000000 -0.01000000
2.99636075 2.99636075 2.99636075 2.99636075 2.99636075 2.99636075
2.99636075 2.99636075 2.99636075 2.99636075 2.99636075 2.99636075
5.22437810 5.22437810 5.22437810 5.22437810 5.22437810 5.22437810
5.22437810 5.22437810 5.22437810 5.22437810 5.22437810 5.22437810
7.22999218 7.22999218 7.22999218 7.22999218 7.22999218 7.22999218
7.22999218 7.22999218 7.22999218 7.22999218 7.22999218 7.22999218
9.10358160 9.10358160 9.10358160 9.10358160 9.10358160 9.10358160
9.10358160 9.10358160 9.10358160 9.10358160 9.10358160 9.10358160
10.88474568 10.88474568 10.88474568 10.88474568 10.88474568 10.88474568
10.88474568 10.88474568 10.88474568 10.88474568 10.88474568 10.88474568
12.59555855 12.59555855 12.59555855 12.59555855 12.59555855 12.59555855
12.59555855 12.59555855 12.59555855 12.59555855 12.59555855 12.59555855
14.25000000 14.25000000 14.25000000 14.25000000 14.25000000 14.25000000
14.25000000 14.25000000 14.25000000 14.25000000 14.25000000 14.25000000
Binary file added paper/ffd_dvs.pdf
Binary file not shown.
Binary file added paper/ffd_multi.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 2827954

Please sign in to comment.